Billy 164 Report post Posted June 2, 2016 Usage: Just add an NPC with the BossRecordNpc as its function, and add the desired bosses to the BossRecord.Tracked table. (before closing the server, use the &lua BossRecord.Clear() command to reset the times) Script : http://pastebin.com/Vy19L2ky 9 Quote Share this post Link to post Share on other sites
V3ct0r 2,117 Report post Posted June 3, 2016 Good work, @7n6! I will translate it and put to Russian section if you don't mind 2 Quote Some useful links / Полезные ссылки Tips for making a topic in 'Questions & Help' / Рекомендации по созданию тем в разделе "Помощь" Server Advertising Section Rules / Правила раздела "Реклама серверов" Available e-mail domains for registration / Допустимые e-mail домены для регистрации User groups / Группы пользователей User ranks / Звания пользователей "Broken" pictures on the forum / "Битые" изображения на форуме Beware of scammers! / Осторожно, мошенники! My developments / Мои разработки Mods for client and server / Моды для клиента и сервера PKOdev.NET website for Tales of Pirates Server / PKOdev.NET веб-обвязка для сервера Пиратии I do not provide any help in private messages and outside the forum. Use 'Questions & Help' section please. Thank you for understanding! Я не оказываю какую-либо помощь в личных сообщениях и вне форума. Пожалуйста, используйте раздел "Пиратия: Помощь". Благодарю за понимание! Share this post Link to post Share on other sites
Ultrasoth 1 Report post Posted June 4, 2016 exactly where this is going: Quote MissionSdk.lua : ActionsProc : elseif actions.func == BossRecord.Reload then local ret = BossRecord.Reload(character) Quote Share this post Link to post Share on other sites
Billy 164 Report post Posted June 4, 2016 In the actionsproc function in missionsddk you add it in the else if statement block Quote Share this post Link to post Share on other sites
Faller 93 Report post Posted September 20, 2016 @Billy Hello! I tried installing your extension but I got a problem. I put the ActionProc and added the lua to my extension folder, but whenever I start the gameserver, it just hangs loading the plugin. It loads all the others and then freezes on Boss Record NPC. Any ideas of what could be happening? Btw, great work! Quote Share this post Link to post Share on other sites
Billy 164 Report post Posted September 20, 2016 2 minutes ago, Faller said: @Billy Hello! I tried installing your extension but I got a problem. I put the ActionProc and added the lua to my extension folder, but whenever I start the gameserver, it just hangs loading the plugin. It loads all the others and then freezes on Boss Record NPC. Any ideas of what could be happening? Btw, great work! Did you make sure that the path to BossRecord.SavePath exists, but the file itself doesnt? 1 Quote Share this post Link to post Share on other sites
Faller 93 Report post Posted September 20, 2016 (edited) 22 hours ago, Billy said: Did you make sure that the path to BossRecord.SavePath exists, but the file itself doesnt? @Billy Oh wow, that was my problem lol I didn't create the folder "logs" inside "Boss Timer". Thanks so much for the fast answer ^^ Edited September 21, 2016 by Faller Quote Share this post Link to post Share on other sites
HILO 0 Report post Posted November 4, 2016 Great release, but May I ask which hook is required for this? Quote Share this post Link to post Share on other sites
TheSamurai 3 Report post Posted November 4, 2016 Can you please update this @Billy ? It will be great if you can see the drops of the boss too Thank you Quote Share this post Link to post Share on other sites
Rinor 59 Report post Posted November 8, 2016 (edited) On 11/4/2016 at 3:29 PM, TheSamurai said: Can you please update this @Billy ? It will be great if you can see the drops of the boss too Thank you BossFolder = "script/extension/Boss Knowledge/BossLogs/" print( "* Loading Boss Knowledge" ) Characterinfo_path = "resource\\characterinfo.txt" -- scanned characterinfo path -- ---------------- -- Table Index's -- ---------------- MonsterKnowledge = {} RespawnBoss = {} BossToRecord = {} MonstersToRecord = {} -- ---------------- -- Bosses IDS -- ---------------- MonstersToRecord[1] = 805 MonstersToRecord[2] = 789 MonstersToRecord[3] = 1302 MonstersToRecord[4] = 757 MonstersToRecord[5] = 1265 MonstersToRecord[6] = 1204 MonstersToRecord[7] = 1267 MonstersToRecord[8] = 1244 -- -------------------- -- Bosses Respawn Time -- -------------------- -- MonsterID / Time in seconds RespawnBoss[805] = 10800 RespawnBoss[789] = 86400 RespawnBoss[1302] = 604800 RespawnBoss[757] = 7200 RespawnBoss[1265] = 14400 RespawnBoss[1204] = 14400 RespawnBoss[1267] = 30000 RespawnBoss[1244] = 39600 -- ---------------------------- -- Record tables for monsters -- ---------------------------- for i,v in pairs (MonstersToRecord) do BossToRecord[v] = true end function file_exists(name) local f=io.open(name,"r") if f~=nil then io.close(f ) return true else return false end end -- ------------------------- -- NPC SDK -- ----------------- -- elseif item.func == CheckMonsterSat then -- return CheckMonsterSat( character,item.p1) -- --------------------------- -- CUSTOM SPLIT FUNCTION -- --------------------------- function split(str, delim, maxNb) -- Eliminate bad cases... if string.find(str, delim) == nil then return { str } end if maxNb == nil or maxNb < 1 then maxNb = 0 -- No limit end local result = {} local pat = "(.-)" .. delim .. "()" local nb = 0 local lastPos for part, pos in string.gfind(str, pat) do nb = nb + 1 result[nb] = part lastPos = pos if nb == maxNb then break end end -- Handle the last field if nb ~= maxNb then result[nb + 1] = string.sub(str, lastPos) end return result end -- --------------------------- -- SCAN CHARACTERINFO -- --------------------------- function ScanMonsterKnowledge(file) local fp = assert(io.open (file)) for line in fp:lines() do local position = string.find(line, "[ \t]*//") if (position ~= 1) then local data = split(line,"\t") local c1 = tonumber(data[1]) if c1 ~= nil then MonsterKnowledge[c1] = {Name = {tostring(data[2])},Skills = {data[45]},Drops = {data[47]},Lv = data[61],MaxHP=data[62],MaxSP=data[64],MinAtk=data[66],MaxAtk=data[67],Pr=data[68],Def=data[69],Hr=data[70],Dodge=data[71],Exp=data[91] } end end end end -- ---------------------------- -- Run characterinfo.txt scan -- ---------------------------- ScanMonsterKnowledge(Characterinfo_path) -- --------------------------- -- CHECK STATUS -- --------------------------- function CheckBossRespawn(id) if file_exists(GetResPath(BossFolder..""..id..".txt")) == false then table.save({LastKilled = 0 , RecordRespawn = 0 },GetResPath(BossFolder..""..id..".txt"),"a") end local Boss = table.load(GetResPath(BossFolder..""..id..".txt"),"r") if Boss.RecordRespawn ~= 0 then local RemainingTime = Boss.RecordRespawn - os.time() if RemainingTime <= 1 then Boss.LastKilled = 0 Boss.RecordRespawn = 0 table.save(Boss,GetResPath(BossFolder..""..id..".txt"),"w") end local notice = "Dead" local notice1 = "Remaining Respawn time: "..GetTime(RemainingTime).."!" return notice,notice1 end if Boss.RecordRespawn == 0 then local noticey = "Alive" local noticex = "Boss: "..MonsterKnowledge[id].Name[1].." is still alive!" return noticey,noticex end end -- --------------------------- -- CHECK LAST KILLER -- --------------------------- function LastKillBossName(id) if file_exists(GetResPath(BossFolder..""..id..".txt")) == false then table.save({LastKilled = 0 , RecordRespawn = 0 },GetResPath(BossFolder..""..id..".txt"),"a") end local Boss = table.load(GetResPath(BossFolder..""..id..".txt"),"r") if Boss.LastKilled == 0 then killer = "Nobody" else killer = Boss.LastKilled end return killer end -- ---------------------------- -- NPC Function -- ---------------------------- function bossknowl() Talk(1,"Graves: Hello, I can show you some information about bosses! Pick a boss already and check the information about it.") for i,v in pairs(MonstersToRecord) do Text(1,""..MonsterKnowledge[v].Name[1].."",CheckMonsterSat,v) end end -- --------------------------- -- LOADING STATS -- --------------------------- function CheckMonsterSat(cha,id) local MonsterName = MonsterKnowledge[id].Name[1] local Lv = MonsterKnowledge[id].Lv local Hp = MonsterKnowledge[id].MaxHP local Sp = MonsterKnowledge[id].MaxSP local mAtk = MonsterKnowledge[id].MinAtk local mxAtk = MonsterKnowledge[id].MaxAtk local Pr = MonsterKnowledge[id].Pr local Def = MonsterKnowledge[id].Def local Hr = MonsterKnowledge[id].Hr local Dodge = MonsterKnowledge[id].Dodge local Exp = MonsterKnowledge[id].Exp local Drops = MonsterKnowledge[id].Drops for i,v in pairs(Drops)do end local Stat,Notice = CheckBossRespawn(id) local LastKill = LastKillBossName(id) HelpInfo(cha,0,"Boss: "..MonsterName.." Information_ Lv:"..Lv.." Hp: "..Hp.." Sp: "..Sp.."_ Min Attack: "..mAtk.." Max Attack: "..mxAtk.."_ Physical Resistance: "..Pr.." Defense: "..Def.."_ Hit Rate: "..Hr.." Dodge: "..Dodge.." Exp: "..Exp.."_ Status: "..Stat.." Last Killer: "..LastKill.." _ "..Notice.."")-- _ Drops : "..Dropsx.."") end -- --------------------------- -- GET TIME IN SECOND -- --------------------------- function GetTime(Seconds) if tonumber(Seconds) == 0 then return "00:00:00"; else Hours = string.format("%02.f", math.floor(tonumber(Seconds)/3600)); Mins = string.format("%02.f", math.floor(tonumber(Seconds)/60 - (Hours*60))); Secs = string.format("%02.f", math.floor(tonumber(Seconds) - Hours*3600 - Mins *60)); return Hours..":"..Mins..":"..Secs end end -- --------------------------- -- PLAYER KILL BOSS HOOK -- --------------------------- function RecordKilledBosses(z,dead,atk) local GetKillerName = GetChaDefaultName(atk) local GetBossName = GetChaDefaultName(dead) local GetBossID = GetChaID(dead) local DisplayCurrentTime = ""..os.date("%H")..":"..os.date("%M")..":"..os.date("%S").."" if BossToRecord[GetBossID] == true then local Boss = table.load(GetResPath(BossFolder..""..GetBossID..".txt"),"r") Boss.RecordRespawn = os.time() + RespawnBoss[GetBossID] Boss.LastKilled = GetKillerName table.save(Boss,GetResPath(BossFolder..""..GetBossID..".txt"),"w") Notice("<BOSS>: "..GetBossName.." has been defeated by ["..GetKillerName.."] at ["..DisplayCurrentTime.."]!") end end Hook:AddPostHook("GetExp_PKM",RecordKilledBosses) This one has HP ,SP , DROPS etc.. about bosses Add this script into a .lua file and create a folder " Boss Knowledge " like this: script/extension/Boss Knowledge/ Dont forget to make a folder name " Boss Logs " like this: script/extension/Boss Knowledge/BossLogs/ Edited November 8, 2016 by Rinor Quote Share this post Link to post Share on other sites
Vasil 71 Report post Posted November 8, 2016 1 hour ago, Rinor said: BossFolder = "script/extension/Boss Knowledge/BossLogs/" print( "* Loading Boss Knowledge" ) Characterinfo_path = "resource\\characterinfo.txt" -- scanned characterinfo path -- ---------------- -- Table Index's -- ---------------- MonsterKnowledge = {} RespawnBoss = {} BossToRecord = {} MonstersToRecord = {} -- ---------------- -- Bosses IDS -- ---------------- MonstersToRecord[1] = 805 MonstersToRecord[2] = 789 MonstersToRecord[3] = 1302 MonstersToRecord[4] = 757 MonstersToRecord[5] = 1265 MonstersToRecord[6] = 1204 MonstersToRecord[7] = 1267 MonstersToRecord[8] = 1244 -- -------------------- -- Bosses Respawn Time -- -------------------- -- MonsterID / Time in seconds RespawnBoss[805] = 10800 RespawnBoss[789] = 86400 RespawnBoss[1302] = 604800 RespawnBoss[757] = 7200 RespawnBoss[1265] = 14400 RespawnBoss[1204] = 14400 RespawnBoss[1267] = 30000 RespawnBoss[1244] = 39600 -- ---------------------------- -- Record tables for monsters -- ---------------------------- for i,v in pairs (MonstersToRecord) do BossToRecord[v] = true end function file_exists(name) local f=io.open(name,"r") if f~=nil then io.close(f ) return true else return false end end -- ------------------------- -- NPC SDK -- ----------------- -- elseif item.func == CheckMonsterSat then -- return CheckMonsterSat( character,item.p1) -- --------------------------- -- CUSTOM SPLIT FUNCTION -- --------------------------- function split(str, delim, maxNb) -- Eliminate bad cases... if string.find(str, delim) == nil then return { str } end if maxNb == nil or maxNb < 1 then maxNb = 0 -- No limit end local result = {} local pat = "(.-)" .. delim .. "()" local nb = 0 local lastPos for part, pos in string.gfind(str, pat) do nb = nb + 1 result[nb] = part lastPos = pos if nb == maxNb then break end end -- Handle the last field if nb ~= maxNb then result[nb + 1] = string.sub(str, lastPos) end return result end -- --------------------------- -- SCAN CHARACTERINFO -- --------------------------- function ScanMonsterKnowledge(file) local fp = assert(io.open (file)) for line in fp:lines() do local position = string.find(line, "[ \t]*//") if (position ~= 1) then local data = split(line,"\t") local c1 = tonumber(data[1]) if c1 ~= nil then MonsterKnowledge[c1] = {Name = {tostring(data[2])},Skills = {data[45]},Drops = {data[47]},Lv = data[61],MaxHP=data[62],MaxSP=data[64],MinAtk=data[66],MaxAtk=data[67],Pr=data[68],Def=data[69],Hr=data[70],Dodge=data[71],Exp=data[91] } end end end end -- ---------------------------- -- Run characterinfo.txt scan -- ---------------------------- ScanMonsterKnowledge(Characterinfo_path) -- --------------------------- -- CHECK STATUS -- --------------------------- function CheckBossRespawn(id) if file_exists(GetResPath(BossFolder..""..id..".txt")) == false then table.save({LastKilled = 0 , RecordRespawn = 0 },GetResPath(BossFolder..""..id..".txt"),"a") end local Boss = table.load(GetResPath(BossFolder..""..id..".txt"),"r") if Boss.RecordRespawn ~= 0 then local RemainingTime = Boss.RecordRespawn - os.time() if RemainingTime <= 1 then Boss.LastKilled = 0 Boss.RecordRespawn = 0 table.save(Boss,GetResPath(BossFolder..""..id..".txt"),"w") end local notice = "Dead" local notice1 = "Remaining Respawn time: "..GetTime(RemainingTime).."!" return notice,notice1 end if Boss.RecordRespawn == 0 then local noticey = "Alive" local noticex = "Boss: "..MonsterKnowledge[id].Name[1].." is still alive!" return noticey,noticex end end -- --------------------------- -- CHECK LAST KILLER -- --------------------------- function LastKillBossName(id) if file_exists(GetResPath(BossFolder..""..id..".txt")) == false then table.save({LastKilled = 0 , RecordRespawn = 0 },GetResPath(BossFolder..""..id..".txt"),"a") end local Boss = table.load(GetResPath(BossFolder..""..id..".txt"),"r") if Boss.LastKilled == 0 then killer = "Nobody" else killer = Boss.LastKilled end return killer end -- ---------------------------- -- NPC Function -- ---------------------------- function bossknowl() Talk(1,"Graves: Hello, I can show you some information about bosses! Pick a boss already and check the information about it.") for i,v in pairs(MonstersToRecord) do Text(1,""..MonsterKnowledge[v].Name[1].."",CheckMonsterSat,v) end end -- --------------------------- -- LOADING STATS -- --------------------------- function CheckMonsterSat(cha,id) local MonsterName = MonsterKnowledge[id].Name[1] local Lv = MonsterKnowledge[id].Lv local Hp = MonsterKnowledge[id].MaxHP local Sp = MonsterKnowledge[id].MaxSP local mAtk = MonsterKnowledge[id].MinAtk local mxAtk = MonsterKnowledge[id].MaxAtk local Pr = MonsterKnowledge[id].Pr local Def = MonsterKnowledge[id].Def local Hr = MonsterKnowledge[id].Hr local Dodge = MonsterKnowledge[id].Dodge local Exp = MonsterKnowledge[id].Exp local Drops = MonsterKnowledge[id].Drops for i,v in pairs(Drops)do end local Stat,Notice = CheckBossRespawn(id) local LastKill = LastKillBossName(id) HelpInfo(cha,0,"Boss: "..MonsterName.." Information_ Lv:"..Lv.." Hp: "..Hp.." Sp: "..Sp.."_ Min Attack: "..mAtk.." Max Attack: "..mxAtk.."_ Physical Resistance: "..Pr.." Defense: "..Def.."_ Hit Rate: "..Hr.." Dodge: "..Dodge.." Exp: "..Exp.."_ Status: "..Stat.." Last Killer: "..LastKill.." _ "..Notice.."")-- _ Drops : "..Dropsx.."") end -- --------------------------- -- GET TIME IN SECOND -- --------------------------- function GetTime(Seconds) if tonumber(Seconds) == 0 then return "00:00:00"; else Hours = string.format("%02.f", math.floor(tonumber(Seconds)/3600)); Mins = string.format("%02.f", math.floor(tonumber(Seconds)/60 - (Hours*60))); Secs = string.format("%02.f", math.floor(tonumber(Seconds) - Hours*3600 - Mins *60)); return Hours..":"..Mins..":"..Secs end end -- --------------------------- -- PLAYER KILL BOSS HOOK -- --------------------------- function RecordKilledBosses(z,dead,atk) local GetKillerName = GetChaDefaultName(atk) local GetBossName = GetChaDefaultName(dead) local GetBossID = GetChaID(dead) local DisplayCurrentTime = ""..os.date("%H")..":"..os.date("%M")..":"..os.date("%S").."" if BossToRecord[GetBossID] == true then local Boss = table.load(GetResPath(BossFolder..""..GetBossID..".txt"),"r") Boss.RecordRespawn = os.time() + RespawnBoss[GetBossID] Boss.LastKilled = GetKillerName table.save(Boss,GetResPath(BossFolder..""..GetBossID..".txt"),"w") Notice("<BOSS>: "..GetBossName.." has been defeated by ["..GetKillerName.."] at ["..DisplayCurrentTime.."]!") end end Hook:AddPostHook("GetExp_PKM",RecordKilledBosses) This one has HP ,SP , DROPS etc.. about bosses Add this script into a .lua file and create a folder " Boss Knowledge " like this: script/extension/Boss Knowledge/ Dont forget to make a folder name " Boss Logs " like this: script/extension/Boss Knowledge/BossLogs/ Did Saeed give you authorization to share his work? I guess it was been for sale.Atleast give him credit. Quote Share this post Link to post Share on other sites
Rinor 59 Report post Posted November 8, 2016 11 minutes ago, Vasil said: Did Saeed give you authorization to share his work? I guess it was been for sale.Atleast give him credit. Well this has been shared in many server files which is at archive, such rainbow files soo Quote Share this post Link to post Share on other sites
TheSamurai 3 Report post Posted November 9, 2016 8 hours ago, Rinor said: BossFolder = "script/extension/Boss Knowledge/BossLogs/" print( "* Loading Boss Knowledge" ) Characterinfo_path = "resource\\characterinfo.txt" -- scanned characterinfo path -- ---------------- -- Table Index's -- ---------------- MonsterKnowledge = {} RespawnBoss = {} BossToRecord = {} MonstersToRecord = {} -- ---------------- -- Bosses IDS -- ---------------- MonstersToRecord[1] = 805 MonstersToRecord[2] = 789 MonstersToRecord[3] = 1302 MonstersToRecord[4] = 757 MonstersToRecord[5] = 1265 MonstersToRecord[6] = 1204 MonstersToRecord[7] = 1267 MonstersToRecord[8] = 1244 -- -------------------- -- Bosses Respawn Time -- -------------------- -- MonsterID / Time in seconds RespawnBoss[805] = 10800 RespawnBoss[789] = 86400 RespawnBoss[1302] = 604800 RespawnBoss[757] = 7200 RespawnBoss[1265] = 14400 RespawnBoss[1204] = 14400 RespawnBoss[1267] = 30000 RespawnBoss[1244] = 39600 -- ---------------------------- -- Record tables for monsters -- ---------------------------- for i,v in pairs (MonstersToRecord) do BossToRecord[v] = true end function file_exists(name) local f=io.open(name,"r") if f~=nil then io.close(f ) return true else return false end end -- ------------------------- -- NPC SDK -- ----------------- -- elseif item.func == CheckMonsterSat then -- return CheckMonsterSat( character,item.p1) -- --------------------------- -- CUSTOM SPLIT FUNCTION -- --------------------------- function split(str, delim, maxNb) -- Eliminate bad cases... if string.find(str, delim) == nil then return { str } end if maxNb == nil or maxNb < 1 then maxNb = 0 -- No limit end local result = {} local pat = "(.-)" .. delim .. "()" local nb = 0 local lastPos for part, pos in string.gfind(str, pat) do nb = nb + 1 result[nb] = part lastPos = pos if nb == maxNb then break end end -- Handle the last field if nb ~= maxNb then result[nb + 1] = string.sub(str, lastPos) end return result end -- --------------------------- -- SCAN CHARACTERINFO -- --------------------------- function ScanMonsterKnowledge(file) local fp = assert(io.open (file)) for line in fp:lines() do local position = string.find(line, "[ \t]*//") if (position ~= 1) then local data = split(line,"\t") local c1 = tonumber(data[1]) if c1 ~= nil then MonsterKnowledge[c1] = {Name = {tostring(data[2])},Skills = {data[45]},Drops = {data[47]},Lv = data[61],MaxHP=data[62],MaxSP=data[64],MinAtk=data[66],MaxAtk=data[67],Pr=data[68],Def=data[69],Hr=data[70],Dodge=data[71],Exp=data[91] } end end end end -- ---------------------------- -- Run characterinfo.txt scan -- ---------------------------- ScanMonsterKnowledge(Characterinfo_path) -- --------------------------- -- CHECK STATUS -- --------------------------- function CheckBossRespawn(id) if file_exists(GetResPath(BossFolder..""..id..".txt")) == false then table.save({LastKilled = 0 , RecordRespawn = 0 },GetResPath(BossFolder..""..id..".txt"),"a") end local Boss = table.load(GetResPath(BossFolder..""..id..".txt"),"r") if Boss.RecordRespawn ~= 0 then local RemainingTime = Boss.RecordRespawn - os.time() if RemainingTime <= 1 then Boss.LastKilled = 0 Boss.RecordRespawn = 0 table.save(Boss,GetResPath(BossFolder..""..id..".txt"),"w") end local notice = "Dead" local notice1 = "Remaining Respawn time: "..GetTime(RemainingTime).."!" return notice,notice1 end if Boss.RecordRespawn == 0 then local noticey = "Alive" local noticex = "Boss: "..MonsterKnowledge[id].Name[1].." is still alive!" return noticey,noticex end end -- --------------------------- -- CHECK LAST KILLER -- --------------------------- function LastKillBossName(id) if file_exists(GetResPath(BossFolder..""..id..".txt")) == false then table.save({LastKilled = 0 , RecordRespawn = 0 },GetResPath(BossFolder..""..id..".txt"),"a") end local Boss = table.load(GetResPath(BossFolder..""..id..".txt"),"r") if Boss.LastKilled == 0 then killer = "Nobody" else killer = Boss.LastKilled end return killer end -- ---------------------------- -- NPC Function -- ---------------------------- function bossknowl() Talk(1,"Graves: Hello, I can show you some information about bosses! Pick a boss already and check the information about it.") for i,v in pairs(MonstersToRecord) do Text(1,""..MonsterKnowledge[v].Name[1].."",CheckMonsterSat,v) end end -- --------------------------- -- LOADING STATS -- --------------------------- function CheckMonsterSat(cha,id) local MonsterName = MonsterKnowledge[id].Name[1] local Lv = MonsterKnowledge[id].Lv local Hp = MonsterKnowledge[id].MaxHP local Sp = MonsterKnowledge[id].MaxSP local mAtk = MonsterKnowledge[id].MinAtk local mxAtk = MonsterKnowledge[id].MaxAtk local Pr = MonsterKnowledge[id].Pr local Def = MonsterKnowledge[id].Def local Hr = MonsterKnowledge[id].Hr local Dodge = MonsterKnowledge[id].Dodge local Exp = MonsterKnowledge[id].Exp local Drops = MonsterKnowledge[id].Drops for i,v in pairs(Drops)do end local Stat,Notice = CheckBossRespawn(id) local LastKill = LastKillBossName(id) HelpInfo(cha,0,"Boss: "..MonsterName.." Information_ Lv:"..Lv.." Hp: "..Hp.." Sp: "..Sp.."_ Min Attack: "..mAtk.." Max Attack: "..mxAtk.."_ Physical Resistance: "..Pr.." Defense: "..Def.."_ Hit Rate: "..Hr.." Dodge: "..Dodge.." Exp: "..Exp.."_ Status: "..Stat.." Last Killer: "..LastKill.." _ "..Notice.."")-- _ Drops : "..Dropsx.."") end -- --------------------------- -- GET TIME IN SECOND -- --------------------------- function GetTime(Seconds) if tonumber(Seconds) == 0 then return "00:00:00"; else Hours = string.format("%02.f", math.floor(tonumber(Seconds)/3600)); Mins = string.format("%02.f", math.floor(tonumber(Seconds)/60 - (Hours*60))); Secs = string.format("%02.f", math.floor(tonumber(Seconds) - Hours*3600 - Mins *60)); return Hours..":"..Mins..":"..Secs end end -- --------------------------- -- PLAYER KILL BOSS HOOK -- --------------------------- function RecordKilledBosses(z,dead,atk) local GetKillerName = GetChaDefaultName(atk) local GetBossName = GetChaDefaultName(dead) local GetBossID = GetChaID(dead) local DisplayCurrentTime = ""..os.date("%H")..":"..os.date("%M")..":"..os.date("%S").."" if BossToRecord[GetBossID] == true then local Boss = table.load(GetResPath(BossFolder..""..GetBossID..".txt"),"r") Boss.RecordRespawn = os.time() + RespawnBoss[GetBossID] Boss.LastKilled = GetKillerName table.save(Boss,GetResPath(BossFolder..""..GetBossID..".txt"),"w") Notice("<BOSS>: "..GetBossName.." has been defeated by ["..GetKillerName.."] at ["..DisplayCurrentTime.."]!") end end Hook:AddPostHook("GetExp_PKM",RecordKilledBosses) This one has HP ,SP , DROPS etc.. about bosses Add this script into a .lua file and create a folder " Boss Knowledge " like this: script/extension/Boss Knowledge/ Dont forget to make a folder name " Boss Logs " like this: script/extension/Boss Knowledge/BossLogs/ Drop doesn't work. I already configure it properly along with the comment on the drop function. When i try to use the NPC and see the monster information system says this: npc[Boss Knowledge]script info manage function [NpcProc] transfer failed! maybe there are missing scripts? I hope someone can do this Quote Share this post Link to post Share on other sites
Saeed 26 Report post Posted November 9, 2016 (edited) woah, similar to a script i made <3 edit: noticed that my script was there lmao, i already have integrated the drop thingy idk why u guys dont have it. Edited November 9, 2016 by Saeed Quote Share this post Link to post Share on other sites
HILO 0 Report post Posted November 9, 2016 I keep getting this error, is there anything i'm messing? Quote Share this post Link to post Share on other sites
Danny 31 Report post Posted November 9, 2016 32 minutes ago, HILO said: I keep getting this error, is there anything i'm messing? Ur probably missing Hook.lua file Quote Share this post Link to post Share on other sites
Rinor 59 Report post Posted November 9, 2016 12 hours ago, TheSamurai said: Drop doesn't work. I already configure it properly along with the comment on the drop function. When i try to use the NPC and see the monster information system says this: npc[Boss Knowledge]script info manage function [NpcProc] transfer failed! maybe there are missing scripts? I hope someone can do this add this at npcsdk.lua: elseif item.func == CheckMonsterSat then return CheckMonsterSat( character,item.p1) Quote Share this post Link to post Share on other sites
HILO 0 Report post Posted November 9, 2016 2 hours ago, Danny said: Ur probably missing Hook.lua file this is the line: Hook:AddPreHook("GetExp_PKM",BossRecord.CheckDead) I have the GetExp_PKM already loaded. Quote Share this post Link to post Share on other sites
Danny 31 Report post Posted November 9, 2016 15 minutes ago, HILO said: this is the line: Hook:AddPreHook("GetExp_PKM",BossRecord.CheckDead) I have the GetExp_PKM already loaded. what? Its saying Hook is not existent , you probably didn't load the Hook.lua file. Quote Share this post Link to post Share on other sites
HILO 0 Report post Posted November 9, 2016 Quote what? Its saying Hook is not existent , you probably didn't load the Hook.lua file. damn, that's why I asked which hook is needed first? and where may I get it In case I don't have? Quote Share this post Link to post Share on other sites
Shako 97 Report post Posted November 9, 2016 (edited) 6 minutes ago, HILO said: damn, that's why I asked which hook is needed first? and where may I get it In case I don't have? https://ufile.io/28414 then you can load it with: dofile(GetResPath("script/extension/hook.lua")) or any path of your choice. EDIT: ufile.io seems to rename the script. please rename it back to Hook.lua! Edited November 9, 2016 by Shako Quote Sunny Go! Online pko.host Share this post Link to post Share on other sites
TheSamurai 3 Report post Posted November 9, 2016 5 hours ago, Rinor said: add this at npcsdk.lua: elseif item.func == CheckMonsterSat then return CheckMonsterSat( character,item.p1) Already add this bro btw did you already tried this? Does the drop status work to you? Quote Share this post Link to post Share on other sites
Rinor 59 Report post Posted November 10, 2016 18 hours ago, TheSamurai said: Already add this bro btw did you already tried this? Does the drop status work to you? yeah it works fine. Quote Share this post Link to post Share on other sites
crusadel 0 Report post Posted December 22, 2016 Hello Guys Please Help me i have problems i dont know how to fix it! Quote Share this post Link to post Share on other sites
Angelix 374 Report post Posted December 23, 2016 11 hours ago, crusadel said: Hello Guys Please Help me i have problems i dont know how to fix it! You're loading some scripts wrong, typed something wrong or forgot to properly close a function. Whatever that "getn" is trying to get was not I guess properly. Quote Share this post Link to post Share on other sites