Postado Fevereiro 25, 2020 5 anos Boa noite, achei esse evento em um site gringo, mas ele está dando alguns erros, alguém poderia me ajudar ? eu tentei mexer nele, mas como sou iniciante nessa área, não sei bem se estraguei mais ou melhorei ? Meu servidor é o Alissow Server, version 0.4.1 8.60 Desde já agradeço Esses são os erros que aparecem na distro [25/02/2020 05:33:24] > Loading [MOD] Evento Metin Stone.xml... [25/02/2020 05:33:24] [Error - CreatureScript Interface] [25/02/2020 05:33:24] buffer [25/02/2020 05:33:24] Description: [25/02/2020 05:33:24] [string "names = {'earth stone', 'icy stone', 'fire stone', 'wind stone'..."]:9: unexpected symbol near '=' [25/02/2020 05:33:24] [Error - TalkAction Interface] [25/02/2020 05:33:24] buffer [25/02/2020 05:33:24] Description: [25/02/2020 05:33:24] [string "names = {'earth stone', 'icy stone', 'fire stone', 'wind stone'..."]:9: unexpected symbol near '=' [25/02/2020 05:33:24] [Error - GlobalEvent Interface] [25/02/2020 05:33:24] buffer [25/02/2020 05:33:24] Description: [25/02/2020 05:33:24] [string "names = {'earth stone', 'icy stone', 'fire stone', 'wind stone'..."]:9: unexpected symbol near '=' [25/02/2020 05:33:24] [Error - GlobalEvent Interface] [25/02/2020 05:33:24] buffer [25/02/2020 05:33:24] Description: [25/02/2020 05:33:24] [string "loadBuffer"]:3: attempt to get length of global 'stones_name' (a nil value) [25/02/2020 05:33:24] [Warning - Event::loadScript] Cannot load script (domodlib("Stones_config") [25/02/2020 05:33:24] local daysOpen = {} [25/02/2020 05:33:24] local monst = stones_name[math.random(1, #stones_name)] [25/02/2020 05:33:24] local poss = pos[math.random(1, #pos)] [25/02/2020 05:33:24] for k, v in pairs(days) do [25/02/2020 05:33:24] table.insert(daysOpen, k) [25/02/2020 05:33:24] end [25/02/2020 05:33:24] function onThink(interval) [25/02/2020 05:33:24] if isInArray(daysOpen, os.date('%A')) then [25/02/2020 05:33:24] if isInArray(days[os.date('%A')], os.date('%X', os.time())) then [25/02/2020 05:33:24] print(monst, poss) [25/02/2020 05:33:24] if not(monst) then return TRUE end [25/02/2020 05:33:24] doCreateMonster(monst.name,poss.pos) [25/02/2020 05:33:24] doBroadcastMessage('[Event Stones]\n '.. monst.name ..' have been spawn. Find and defeat it!', 22) [25/02/2020 05:33:24] end [25/02/2020 05:33:24] end [25/02/2020 05:33:24] return true [25/02/2020 05:33:24] end [25/02/2020 05:33:24] ) Script MOD <?xml version="1.0" encoding="UTF-8"?> <mod name="Stones_Event Items" enabled="yes"> <config name="Stones_config"><![CDATA[ names = {'earth stone', 'icy stone', 'fire stone', 'wind stone'} stones_name = { [1] = {name="Earth Stone"}, [2] = {name="Icy Stone"}, [3] = {name="Fire Stone"}, [4] = {name="Wind Stone"} }, pos = { [1] = {{x=95, y=57, z=7}}, [2] = {{x=103, y=57, z=7}}, [3] = {{x=90, y=58, z=7}}, [4] = {{x=80, y=58, z=7}} }, days = {['Tuesday'] = {'05:29:00'}, ['Sunday'] = {'03:46:20'} }, stones = { ["earth stone"] = { [90] = {m = {'carniphila','earth elemental','bog raider'}, n = {6, 7}}, [80] = {m = {'bog raider','earth elemental'}, n = {6, 7}}, [70] = {m = {'giant spider','bog raider'}, n = {6, 7}}, [60] = {m = {'hydra','lich','giant spider','bog raider'}, n = {6, 7}}, [50] = {m = {'hydra','bog raider','serpent spawn'}, n = {6, 7}}, [40] = {m = {'hydra','defiler','serpent spawn'}, n = {6, 7}}, [30] = {m = {'medusa','hydra','serpent spawn','defiler'}, n = {6, 7}}, [20] = {m = {'medusa','lost soul','hydra','serpent spawn'}, n = {6, 7}}, [10] = {m = {'juggernaut','son of verminor','medusa'}, n = {5, 6}}, [1] = {m = {'medusa','juggernaut'}, n = {5,7}} }, ["icy stone"] = { [90] = {m = {'ice golem','frost dragon'}, n = {6, 7}}, [80] = {m = {'frost dragon','frost dragon hatchling'}, n = {6, 7}}, [70] = {m = {'frost dragon','crystal spider'}, n = {6, 7}}, [60] = {m = {'frost dragon','crystal spider'}, n = {7, 7}}, [50] = {m = {'frost dragon','crystal spider'}, n = {7, 7}}, [40] = {m = {'frost dragon'}, n = {7, 7}}, [30] = {m = {'frost dragon'}, n = {7, 8}}, [20] = {m = {'frost dragon'}, n = {7, 8}}, [10] = {m = {'yeti','frost dragon'}, n = {5, 7}}, [1] = {m = {'yeti'}, n = {2,3}} }, ["fire stone"] = { [90] = {m = {'fire elemental','dragon','dragon lord',' dragon lord hatchling'}, n = {6, 7}}, [80] = {m = {'dragon lord hatchling','dragon lord'}, n = {6, 7}}, [70] = {m = {'dragon lord','diabolic imp'}, n = {6, 7}}, [60] = {m = {'dragon lord','diabolic imp'}, n = {6, 7}}, [50] = {m = {'dragon lord','demodras','diabolic imp'}, n = {6, 7}}, [40] = {m = {'dragon lord','diabolic imp','hellfire fighter'}, n = {5, 7}}, [30] = {m = {'diabolic imp','hellfire fighter','demon'}, n = {6, 7}}, [20] = {m = {'hellfire fighter','demon'}, n = {5, 6}}, [10] = {m = {'demon','hellhound'}, n = {5, 5}}, [1] = {m = {'demon'}, n = {5,5}} }, ["wind stone"] = { [90] = {m = {'gargoyle','stone golem','black knight'}, n = {6, 7}}, [80] = {m = {'black knight','behemoth'}, n = {5, 7}}, [70] = {m = {'black knight','behemoth'}, n = {6, 7}}, [60] = {m = {'behemoth','destroyer'}, n = {6, 7}}, [50] = {m = {'behemoth','destroyer','betrayed wraith'}, n = {6, 7}}, [40] = {m = {'behemoth','destroyer','betrayed wraith'}, n = {6, 7}}, [30] = {m = {'dark torturer','betrayed wraith'}, n = {3, 5}}, [20] = {m = {'dark torturer','grim reaper'}, n = {5, 6}}, [10] = {m = {'blightwalker','undead dragon','grim reaper'}, n = {5, 6}}, [1] = {m = {'undead dragon'}, n = {5,5}} } } function getPercent(number, all) return (number / all) * 100 end function choose(arg) return arg[math.random(#arg)] end ]]></config> <event type="combat" name="Kamulec" event="script"><![CDATA[ domodlib("Stones_config") function onCombat(cid, target) if isMonster(target) then registerCreatureEvent(target, 'Kamulec') end local t = getPercent(getCreatureHealth(target), getCreatureMaxHealth(target)) if isMonster(target) and isInArray(names, getCreatureName(target):lower()) then if t > 90 then doCreatureSetStorage(target, 1000, 91) end for k, v in pairs(stones[getCreatureName(target):lower()]) do if k >= t and getCreatureStorage(target, 1000) > k then local pos = getThingPos(target) for i = 1, math.random(v.n[1], v.n[2]) do local s = {x=pos.x,y=pos.y,z=pos.z} s.x = pos.x + math.random(-2,2) s.y = pos.y + math.random(-2,2) doCreateMonster(choose(v.m), pos, false, false, false) end return doCreatureSetStorage(target, 1000, k) end end end return TRUE end ]]></event> <talkaction log="yes" words="!metin" access="4" event="script"> <![CDATA[ domodlib("Stones_config") function onSay() local monst = stones_name[math.random(1, #stones_name)] local poss = pos[math.random(1, #pos)] print(monst, poss) if not(monst) then return TRUE end doCreateMonster(monst.name,poss.pos) doBroadcastMessage('[Event Stones]\n '.. monst.name ..' have been spawn. Find and defeat it!', 22) return TRUE end ]]> </talkaction> <globalevent name="metinStoneStart" interval="1000" event="script"><![CDATA[ domodlib("Stones_config") local daysOpen = {} local monst = stones_name[math.random(1, #stones_name)] local poss = pos[math.random(1, #pos)] for k, v in pairs(days) do table.insert(daysOpen, k) end function onThink(interval) if isInArray(daysOpen, os.date('%A')) then if isInArray(days[os.date('%A')], os.date('%X', os.time())) then print(monst, poss) if not(monst) then return TRUE end doCreateMonster(monst.name,poss.pos) doBroadcastMessage('[Event Stones]\n '.. monst.name ..' have been spawn. Find and defeat it!', 22) end end return true end ]]></globalevent> <event type="login" name="metinStoneLogin" event="buffer"><![CDATA[ registerCreatureEvent(cid, 'Kamulec') ]]></event> </mod> Editado Fevereiro 25, 2020 5 anos por subhe (veja o histórico de edições)
Postado Fevereiro 27, 2020 5 anos <?xml version="1.0" encoding="UTF-8"?> <mod name="Stones_Event Items" enabled="yes"> <config name="Stones_config"><![CDATA[ names = {'earth stone', 'icy stone', 'fire stone', 'wind stone'} stones_name = { [1] = {name="Earth Stone"}, [2] = {name="Icy Stone"}, [3] = {name="Fire Stone"}, [4] = {name="Wind Stone"} } pos = { [1] = {{x=95, y=57, z=7}}, [2] = {{x=103, y=57, z=7}}, [3] = {{x=90, y=58, z=7}}, [4] = {{x=80, y=58, z=7}} } days = {['Tuesday'] = {'05:29:00'}, ['Sunday'] = {'03:46:20'} } stones = { ["earth stone"] = { [90] = {m = {'carniphila','earth elemental','bog raider'}, n = {6, 7}}, [80] = {m = {'bog raider','earth elemental'}, n = {6, 7}}, [70] = {m = {'giant spider','bog raider'}, n = {6, 7}}, [60] = {m = {'hydra','lich','giant spider','bog raider'}, n = {6, 7}}, [50] = {m = {'hydra','bog raider','serpent spawn'}, n = {6, 7}}, [40] = {m = {'hydra','defiler','serpent spawn'}, n = {6, 7}}, [30] = {m = {'medusa','hydra','serpent spawn','defiler'}, n = {6, 7}}, [20] = {m = {'medusa','lost soul','hydra','serpent spawn'}, n = {6, 7}}, [10] = {m = {'juggernaut','son of verminor','medusa'}, n = {5, 6}}, [1] = {m = {'medusa','juggernaut'}, n = {5,7}} }, ["icy stone"] = { [90] = {m = {'ice golem','frost dragon'}, n = {6, 7}}, [80] = {m = {'frost dragon','frost dragon hatchling'}, n = {6, 7}}, [70] = {m = {'frost dragon','crystal spider'}, n = {6, 7}}, [60] = {m = {'frost dragon','crystal spider'}, n = {7, 7}}, [50] = {m = {'frost dragon','crystal spider'}, n = {7, 7}}, [40] = {m = {'frost dragon'}, n = {7, 7}}, [30] = {m = {'frost dragon'}, n = {7, 8}}, [20] = {m = {'frost dragon'}, n = {7, 8}}, [10] = {m = {'yeti','frost dragon'}, n = {5, 7}}, [1] = {m = {'yeti'}, n = {2,3}} }, ["fire stone"] = { [90] = {m = {'fire elemental','dragon','dragon lord',' dragon lord hatchling'}, n = {6, 7}}, [80] = {m = {'dragon lord hatchling','dragon lord'}, n = {6, 7}}, [70] = {m = {'dragon lord','diabolic imp'}, n = {6, 7}}, [60] = {m = {'dragon lord','diabolic imp'}, n = {6, 7}}, [50] = {m = {'dragon lord','demodras','diabolic imp'}, n = {6, 7}}, [40] = {m = {'dragon lord','diabolic imp','hellfire fighter'}, n = {5, 7}}, [30] = {m = {'diabolic imp','hellfire fighter','demon'}, n = {6, 7}}, [20] = {m = {'hellfire fighter','demon'}, n = {5, 6}}, [10] = {m = {'demon','hellhound'}, n = {5, 5}}, [1] = {m = {'demon'}, n = {5,5}} }, ["wind stone"] = { [90] = {m = {'gargoyle','stone golem','black knight'}, n = {6, 7}}, [80] = {m = {'black knight','behemoth'}, n = {5, 7}}, [70] = {m = {'black knight','behemoth'}, n = {6, 7}}, [60] = {m = {'behemoth','destroyer'}, n = {6, 7}}, [50] = {m = {'behemoth','destroyer','betrayed wraith'}, n = {6, 7}}, [40] = {m = {'behemoth','destroyer','betrayed wraith'}, n = {6, 7}}, [30] = {m = {'dark torturer','betrayed wraith'}, n = {3, 5}}, [20] = {m = {'dark torturer','grim reaper'}, n = {5, 6}}, [10] = {m = {'blightwalker','undead dragon','grim reaper'}, n = {5, 6}}, [1] = {m = {'undead dragon'}, n = {5,5}} } } function getPercent(number, all) return (number / all) * 100 end function choose(arg) return arg[math.random(#arg)] end ]]></config> <event type="combat" name="Kamulec" event="script"><![CDATA[ domodlib("Stones_config") function onCombat(cid, target) if isMonster(target) then registerCreatureEvent(target, 'Kamulec') end local t = getPercent(getCreatureHealth(target), getCreatureMaxHealth(target)) if isMonster(target) and isInArray(names, getCreatureName(target):lower()) then if t > 90 then doCreatureSetStorage(target, 1000, 91) end for k, v in pairs(stones[getCreatureName(target):lower()]) do if k >= t and getCreatureStorage(target, 1000) > k then local pos = getThingPos(target) for i = 1, math.random(v.n[1], v.n[2]) do local s = {x=pos.x,y=pos.y,z=pos.z} s.x = pos.x + math.random(-2,2) s.y = pos.y + math.random(-2,2) doCreateMonster(choose(v.m), pos, false, false, false) end return doCreatureSetStorage(target, 1000, k) end end end return TRUE end ]]></event> <talkaction log="yes" words="!metin" access="4" event="script"> <![CDATA[ domodlib("Stones_config") function onSay() local monst = stones_name[math.random(1, #stones_name)] local poss = pos[math.random(1, #pos)] print(monst, poss) if not(monst) then return TRUE end doCreateMonster(monst.name,poss.pos) doBroadcastMessage('[Event Stones]\n '.. monst.name ..' have been spawn. Find and defeat it!', 22) return TRUE end ]]> </talkaction> <globalevent name="metinStoneStart" interval="1000" event="script"><![CDATA[ domodlib("Stones_config") local daysOpen = {} local monst = stones_name[math.random(1, #stones_name)] local poss = pos[math.random(1, #pos)] for k, v in pairs(days) do table.insert(daysOpen, k) end function onThink(interval) if isInArray(daysOpen, os.date('%A')) then if isInArray(days[os.date('%A')], os.date('%X', os.time())) then print(monst, poss) if not(monst) then return TRUE end doCreateMonster(monst.name,poss.pos) doBroadcastMessage('[Event Stones]\n '.. monst.name ..' have been spawn. Find and defeat it!', 22) end end return true end ]]></globalevent> <event type="login" name="metinStoneLogin" event="buffer"><![CDATA[ registerCreatureEvent(cid, 'Kamulec') ]]></event> </mod> [*Ninguém será digno do sucesso se não usar suas derrotas para conquistá-lo.*] DISCORD: vodkart#6090
Postado Fevereiro 27, 2020 5 anos Autor 1 hora atrás, Vodkart disse: <?xml version="1.0" encoding="UTF-8"?> <mod name="Stones_Event Items" enabled="yes"> <config name="Stones_config"><![CDATA[ names = {'earth stone', 'icy stone', 'fire stone', 'wind stone'} stones_name = { [1] = {name="Earth Stone"}, [2] = {name="Icy Stone"}, [3] = {name="Fire Stone"}, [4] = {name="Wind Stone"} } pos = { [1] = {{x=95, y=57, z=7}}, [2] = {{x=103, y=57, z=7}}, [3] = {{x=90, y=58, z=7}}, [4] = {{x=80, y=58, z=7}} } days = {['Tuesday'] = {'05:29:00'}, ['Sunday'] = {'03:46:20'} } stones = { ["earth stone"] = { [90] = {m = {'carniphila','earth elemental','bog raider'}, n = {6, 7}}, [80] = {m = {'bog raider','earth elemental'}, n = {6, 7}}, [70] = {m = {'giant spider','bog raider'}, n = {6, 7}}, [60] = {m = {'hydra','lich','giant spider','bog raider'}, n = {6, 7}}, [50] = {m = {'hydra','bog raider','serpent spawn'}, n = {6, 7}}, [40] = {m = {'hydra','defiler','serpent spawn'}, n = {6, 7}}, [30] = {m = {'medusa','hydra','serpent spawn','defiler'}, n = {6, 7}}, [20] = {m = {'medusa','lost soul','hydra','serpent spawn'}, n = {6, 7}}, [10] = {m = {'juggernaut','son of verminor','medusa'}, n = {5, 6}}, [1] = {m = {'medusa','juggernaut'}, n = {5,7}} }, ["icy stone"] = { [90] = {m = {'ice golem','frost dragon'}, n = {6, 7}}, [80] = {m = {'frost dragon','frost dragon hatchling'}, n = {6, 7}}, [70] = {m = {'frost dragon','crystal spider'}, n = {6, 7}}, [60] = {m = {'frost dragon','crystal spider'}, n = {7, 7}}, [50] = {m = {'frost dragon','crystal spider'}, n = {7, 7}}, [40] = {m = {'frost dragon'}, n = {7, 7}}, [30] = {m = {'frost dragon'}, n = {7, 8}}, [20] = {m = {'frost dragon'}, n = {7, 8}}, [10] = {m = {'yeti','frost dragon'}, n = {5, 7}}, [1] = {m = {'yeti'}, n = {2,3}} }, ["fire stone"] = { [90] = {m = {'fire elemental','dragon','dragon lord',' dragon lord hatchling'}, n = {6, 7}}, [80] = {m = {'dragon lord hatchling','dragon lord'}, n = {6, 7}}, [70] = {m = {'dragon lord','diabolic imp'}, n = {6, 7}}, [60] = {m = {'dragon lord','diabolic imp'}, n = {6, 7}}, [50] = {m = {'dragon lord','demodras','diabolic imp'}, n = {6, 7}}, [40] = {m = {'dragon lord','diabolic imp','hellfire fighter'}, n = {5, 7}}, [30] = {m = {'diabolic imp','hellfire fighter','demon'}, n = {6, 7}}, [20] = {m = {'hellfire fighter','demon'}, n = {5, 6}}, [10] = {m = {'demon','hellhound'}, n = {5, 5}}, [1] = {m = {'demon'}, n = {5,5}} }, ["wind stone"] = { [90] = {m = {'gargoyle','stone golem','black knight'}, n = {6, 7}}, [80] = {m = {'black knight','behemoth'}, n = {5, 7}}, [70] = {m = {'black knight','behemoth'}, n = {6, 7}}, [60] = {m = {'behemoth','destroyer'}, n = {6, 7}}, [50] = {m = {'behemoth','destroyer','betrayed wraith'}, n = {6, 7}}, [40] = {m = {'behemoth','destroyer','betrayed wraith'}, n = {6, 7}}, [30] = {m = {'dark torturer','betrayed wraith'}, n = {3, 5}}, [20] = {m = {'dark torturer','grim reaper'}, n = {5, 6}}, [10] = {m = {'blightwalker','undead dragon','grim reaper'}, n = {5, 6}}, [1] = {m = {'undead dragon'}, n = {5,5}} } } function getPercent(number, all) return (number / all) * 100 end function choose(arg) return arg[math.random(#arg)] end ]]></config> <event type="combat" name="Kamulec" event="script"><![CDATA[ domodlib("Stones_config") function onCombat(cid, target) if isMonster(target) then registerCreatureEvent(target, 'Kamulec') end local t = getPercent(getCreatureHealth(target), getCreatureMaxHealth(target)) if isMonster(target) and isInArray(names, getCreatureName(target):lower()) then if t > 90 then doCreatureSetStorage(target, 1000, 91) end for k, v in pairs(stones[getCreatureName(target):lower()]) do if k >= t and getCreatureStorage(target, 1000) > k then local pos = getThingPos(target) for i = 1, math.random(v.n[1], v.n[2]) do local s = {x=pos.x,y=pos.y,z=pos.z} s.x = pos.x + math.random(-2,2) s.y = pos.y + math.random(-2,2) doCreateMonster(choose(v.m), pos, false, false, false) end return doCreatureSetStorage(target, 1000, k) end end end return TRUE end ]]></event> <talkaction log="yes" words="!metin" access="4" event="script"> <![CDATA[ domodlib("Stones_config") function onSay() local monst = stones_name[math.random(1, #stones_name)] local poss = pos[math.random(1, #pos)] print(monst, poss) if not(monst) then return TRUE end doCreateMonster(monst.name,poss.pos) doBroadcastMessage('[Event Stones]\n '.. monst.name ..' have been spawn. Find and defeat it!', 22) return TRUE end ]]> </talkaction> <globalevent name="metinStoneStart" interval="1000" event="script"><![CDATA[ domodlib("Stones_config") local daysOpen = {} local monst = stones_name[math.random(1, #stones_name)] local poss = pos[math.random(1, #pos)] for k, v in pairs(days) do table.insert(daysOpen, k) end function onThink(interval) if isInArray(daysOpen, os.date('%A')) then if isInArray(days[os.date('%A')], os.date('%X', os.time())) then print(monst, poss) if not(monst) then return TRUE end doCreateMonster(monst.name,poss.pos) doBroadcastMessage('[Event Stones]\n '.. monst.name ..' have been spawn. Find and defeat it!', 22) end end return true end ]]></globalevent> <event type="login" name="metinStoneLogin" event="buffer"><![CDATA[ registerCreatureEvent(cid, 'Kamulec') ]]></event> </mod> Aparece esse erro e o servidor não abre, fica só aparecendo esses erros [27/02/2020 19:08:00] OTSYS_SQLITE3_PREPARE(): SQLITE ERROR: database disk image is malformed (SELECT "name" FROM "sqlite_master" WHERE "type" = 'table' AND "name" = 'server_config';) [27/02/2020 19:08:00] > Updating database to version: 1... [27/02/2020 19:08:00] OTSYS_SQLITE3_PREPARE(): SQLITE ERROR: database disk image is malformed (CREATE TABLE IF NOT EXISTS "server_config" ("config" VARCHAR(35) NOT NULL DEFAULT '', "value" INTEGER NOT NULL);) [27/02/2020 19:08:00] OTSYS_SQLITE3_PREPARE(): SQLITE ERROR: database disk image is malformed (INSERT INTO "server_config" VALUES ('db_version', 1);) [27/02/2020 19:08:00] > SQLite migration from 0.2 support not available, please use latest database! [27/02/2020 19:08:00] > Database has been updated to version: 1.
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.