Mam problem z tym Bug trackerem: http://tibia.net.pl/threads/560653-Bug-Tracker-System-RPG
Oto błąd po wpisaniu komendy !bug, na default wyświetla się ten napis: 12:32 Your request has been sent. a w konsoli:
Na kanale Bug Tracker nic się nie pojawia. Dzięki za pomoc
Skrypt z Talkactions:
Oto błąd po wpisaniu komendy !bug, na default wyświetla się ten napis: 12:32 Your request has been sent. a w konsoli:
Code:
[15/12/2013 12:33:32] [Error - TalkAction Interface]
[15/12/2013 12:33:32] data/talkactions/scripts/bugtracker.lua:onSay
[15/12/2013 12:33:32] Description:
[15/12/2013 12:33:32] data/talkactions/scripts/bugtracker.lua:31: attempt to call field 'query' (a nil value)
[15/12/2013 12:33:32] stack traceback:
[15/12/2013 12:33:32] data/talkactions/scripts/bugtracker.lua:31: in function <data/talkactions/scripts/bugtracker.lua:1>
Na kanale Bug Tracker nic się nie pojawia. Dzięki za pomoc
Skrypt z Talkactions:
Code:
function onSay(cid, words, param, channel)
local storage = 193728
local seconds = 40
local position_player = getPlayerPosition(cid)
if(param == '') then
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You have to write here your message to administration.")
return true
end
if exhaustion.get(cid, storage) then
pause = math.floor(((exhaustion.get(cid, storage)) + 1))
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You have to wait "..pause.." seconds to be able report next bug.")
return true
end
db.query("INSERT INTO `bug_tracker_ingame` (`id_bug`, `name`, `description`, `posx`, `posy`, `posz`, `time`) VALUES (null, '"..getPlayerName(cid).."', '"..db.escapeString(param).."', "..position_player.x..", "..position_player.y..", "..position_player.z..", "..os.date("%Y", times)..""..os.date("%m", times)..""..os.date("%d", times).." );")
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Your request has been sent.")
exhaustion.set(cid, storage, seconds)
local target = db.getResult("SELECT `name`, `id_bug`, `description`, `posx`, `posy`, `posz` FROM `bug_tracker_ingame` ORDER BY `id_bug` DESC LIMIT 1")
if(target:getID() == -1) then
return true
end
local nickGracza = target:getDataString("name")
local idGracza = target:getDataInt("id_bug")
local desc = target:getDataString("description")
local x = target:getDataInt("posx")
local y = target:getDataInt("posy")
local z = target:getDataInt("posz")
target:free()
for _, pid in ipairs(getPlayersOnline()) do
if getPlayerAccess(pid) > 3 then
doPlayerOpenChannel(pid, 10)
addEvent(doPlayerSendChannelMessage, 500, pid, "Bug Tracker System" , "\n Nr. Zgłoszenia: " .. idGracza .." \n Nick Gracza: " .. nickGracza .. "\n Opis błędu: "..desc .." \n Pozycja gracza: ".. x ..", ".. y ..", ".. z .." \n Data: "..os.date("%x", times).." "..os.date("%X", times).."", TALKTYPE_CHANNEL_O, 10)
end
end
return true
end