• 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!

Few errors in console ...

Wiw3K

New Member
Joined
Apr 16, 2008
Messages
371
Reaction score
3
Hello,
Maybe someone know how to fix it so let me post this there ;)

My Server - TFS 0.3.1

first error is:
Lua:
[Error - CreatureEvent::configureEvent] No valid type for creature event.joinchannel
[Warning - BaseEvents::loadFromXml] Can not configure event

-------------------------------------------------------------------------------------------------------------

my second error is about Fire on PoI:
Lua:
Lua Script Error: [MoveEvents Interface]
data/movements/scripts/PitsOfInferno/firesorc.lua:onStepIn

data/movements/scripts/PitsOfInferno/firesorc.lua:9: attempt to call global 'doPlayerAddHealth' (a nil value)
stack traceback:
        data/movements/scripts/PitsOfInferno/firesorc.lua:9: in function <data/movements/scripts/PitsOfInferno/firesorc.lua:1>

& thats the script i am using:
Lua:
function onStepIn(cid, item, pos)

local zabierz = 300
local kolor = 180
local zycie = getCreatureHealth(cid) 
local topos = getCreaturePosition(cid)  

if item.actionid == 9876 and getPlayerVocation(cid) == 2 or getPlayerVocation(cid) == 3 or getPlayerVocation(cid) == 4 or getPlayerVocation(cid) == 6 or getPlayerVocation(cid) == 7 or getPlayerVocation(cid) == 8 then
doPlayerAddHealth(cid, -zycie)
doSendAnimatedText(topos, zycie, kolor)
doSendMagicEffect(getPlayerPosition(cid), 15)
end

if item.actionid == 9876 and getPlayerVocation(cid) == 1 or getPlayerVocation(cid) == 5 then
doPlayerAddHealth(cid, -zabierz)
doSendAnimatedText(topos, zabierz, kolor)
doSendMagicEffect(getPlayerPosition(cid), 15)
end


if item.actionid == 9876 and getPlayerVocation(cid) == 10 then
doSendMagicEffect(getPlayerPosition(cid), 0)

end
return 1
end

-------------------------------------------------------------------------------------------------------------

oh btw,
one more error about arener npc:
Lua:
Lua Script Error: [Npc interface]
data/npc/scripts/arena.lua:onCreatureSay

data/npc/scripts/arena.lua:30: attempt to compare nil with number
stack traceback:
        data/npc/scripts/arena.lua:30: in function 'callback'
        data/npc/lib/npcsystem/keywordhandler.lua:40: in function 'processMessage'
        data/npc/lib/npcsystem/keywordhandler.lua:168: in function 'processNodeMessage'
        data/npc/lib/npcsystem/keywordhandler.lua:122: in function 'processMessage'
        data/npc/lib/npcsystem/npchandler.lua:371: in function 'onCreatureSay'
        data/npc/scripts/arena.lua:7: in function <data/npc/scripts/arena.lua:7>

thats the script:
Lua:
local keywordHandler = KeywordHandler:new()
local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)

function onCreatureAppear(cid)				npcHandler:onCreatureAppear(cid)			end
function onCreatureDisappear(cid) 			npcHandler:onCreatureDisappear(cid)			end
function onCreatureSay(cid, type, msg) 		npcHandler:onCreatureSay(cid, type, msg)	end
function onThink() 							npcHandler:onThink()						end

function enterArena(cid, message, keywords, parameters, node)
	if(not npcHandler:isFocused(cid)) then
		return false
	end
	local cost = 0
	local levelname = ''
	if getPlayerStorageValue(cid, 42355) < 1 then
		cost = 1000
		levelname = 'greenshore'
		levelneeded = 30
	elseif getPlayerStorageValue(cid, 42355) == 1 then
		cost = 5000
		levelname = 'scrapper'
		levelneeded = 50
	elseif getPlayerStorageValue(cid, 42355) == 2 then
		cost = 10000
		levelname = 'warlord'
		levelneeded = 80
	end
	if string.lower(keywords[1]) == 'yes' and parameters.prepare ~= 1 then
		if(getPlayerLevel(cid) >= levelneeded) then
			if(getPlayerMoney(cid) >= cost) then
				doPlayerRemoveMoney(cid, cost)
				npcHandler:say('Now you can go to test.', cid)
				setPlayerStorageValue(cid, 42351, 1)
			else
				npcHandler:say('You don\'t have ' .. cost .. ' gp! Come back when you will be ready!', cid)
		    end
		else
			npcHandler:say('You don\'t have ' .. levelneeded .. ' level! Come back when you will be ready!', cid)
		end
		npcHandler:resetNpc()
	elseif string.lower(keywords[1]) == 'no' then
		npcHandler:say('Come back later then!', cid)
		npcHandler:resetNpc()
	else
		if getPlayerStorageValue(cid, 42355) < 3 then
			npcHandler:say('You test will be ' .. levelname .. ' level. If you want enter you must pay ' .. cost .. ' gp and have ' .. levelneeded .. ' level. Wanna try?', cid)
		else
			npcHandler:say('You did all arena levels.',cid)
		end
	end
	return true
end

npcHandler:setMessage(MESSAGE_GREET, 'Hello |PLAYERNAME|! Do you want to make arena?')

local yesNode = KeywordNode:new({'yes'}, enterArena, {})
local noNode = KeywordNode:new({'no'}, enterArena, {})

local node1 = keywordHandler:addKeyword({'arena'}, enterArena, {prepare=1})
	node1:addChildKeywordNode(yesNode)
	node1:addChildKeywordNode(noNode)
	
local node1 = keywordHandler:addKeyword({'fight'}, enterArena, {prepare=1})
	node1:addChildKeywordNode(yesNode)
	node1:addChildKeywordNode(noNode)
local node1 = keywordHandler:addKeyword({'yes'}, enterArena, {prepare=1})
	node1:addChildKeywordNode(yesNode)
	node1:addChildKeywordNode(noNode)
npcHandler:addModule(FocusModule:new())


-------------------------------------------------------------------------------------------------------------

---EDIT---
FOUND ONE MORE ABOUT ROPE ?!?!?? WTF?
Lua:
Lua Script Error: [Action Interface]
data/actions/scripts/tools/rope.lua:onUse

luaGetThingFromPos(). Tile not found
 
@poi script

Lua:
function onStepIn(cid, item, position, fromPosition)

local zabierz = 300
local kolor = 180
local zycie = getCreatureHealth(cid) 
local topos = getCreaturePosition(cid) 
local vocations = {2, 3, 4, 6, 7, 8}

	if item.actionid == 9876 and isInArray(vocations, getPlayerVocation(cid)) then
		doCreatureAddHealth(cid, -zycie)
		doSendAnimatedText(position, zycie, kolor)
		doSendMagicEffect(getCreaturePosition(cid), 15)
	end

	if item.actionid == 9876 and isSorcerer(cid) then
		doCreatureAddHealth(cid, -zabierz)
		doSendAnimatedText(position, zabierz, kolor)
		doSendMagicEffect(getCreaturePosition(cid), 15)
	end
end
 
@poi script

Lua:
function onStepIn(cid, item, position, fromPosition)

local zabierz = 300
local kolor = 180
local zycie = getCreatureHealth(cid) 
local topos = getCreaturePosition(cid) 
local vocations = {2, 3, 4, 6, 7, 8}

	if item.actionid == 9876 and isInArray(vocations, getPlayerVocation(cid)) then
		doCreatureAddHealth(cid, -zycie)
		doSendAnimatedText(position, zycie, kolor)
		doSendMagicEffect(getCreaturePosition(cid), 15)
	end

	if item.actionid == 9876 and isSorcerer(cid) then
		doCreatureAddHealth(cid, -zabierz)
		doSendAnimatedText(position, zabierz, kolor)
		doSendMagicEffect(getCreaturePosition(cid), 15)
	end
end
ok thanks , so i need to change "isSorcerer" to every voc , for knight "isKnight" for paladin "isPaladin" , druid - "isDruid" & everything should work ? ;)

how about other errors :|
 
Back
Top