Postado Fevereiro 21, 2013 12 anos Quando alguém morre, aparece esse erro no distro : Mostrar conteúdo oculto [Error - CreatureScript Interface] data/creaturescripts/scripts/playerdeath.lua:onDeath Description: (luaGetCreatureName) Creature not found [Error - CreatureScript Interface] data/creaturescripts/scripts/playerdeath.lua:onDeath Description: (luaGetCreatureName) Creature not found [Error - CreatureScript Interface] data/creaturescripts/scripts/playerdeath.lua:onDeath Description: (luaGetCreatureName) Creature not found mysql_real_query(): INSERT INTO `player_deaths` (`player_id`, `time`, `level`, ` killed_by`, `altkilled_by`) VALUES (6478, 1361476032, 429, '', ''); - MYSQL ERRO R: Unknown column 'time' in 'field list' (1054) mysql_real_query(): DELETE FROM `player_deaths` WHERE `player_id` = 6478 ORDER B Y `time` LIMIT 12; - MYSQL ERROR: Unknown column 'time' in 'order clause' (1054) E o corpo da pessoa não aparece quando morre. se quiser meu playerdeath tá aqui : Mostrar conteúdo oculto local config = { deathListEnabled = getBooleanFromString(getConfigInfo('deathListEnabled')), sqlType = getConfigInfo('sqlType'), maxDeathRecords = getConfigInfo('maxDeathRecords') } config.sqlType = config.sqlType == "sqlite" and DATABASE_ENGINE_SQLITE or DATABASE_ENGINE_MYSQL function onDeath(cid, corpse, lastHitKiller, mostDamageKiller) if(config.deathListEnabled ~= TRUE) then return end local hitKillerName = "field item" local damageKillerName = "" if(lastHitKiller ~= FALSE) then if(isPlayer(lastHitKiller) == TRUE) then hitKillerName = getPlayerGUID(lastHitKiller) else hitKillerName = getCreatureName(lastHitKiller) end if(mostDamageKiller ~= FALSE and mostDamageKiller ~= lastHitKiller and getCreatureName(mostDamageKiller) ~= getCreatureName(lastHitKiller)) then if(isPlayer(mostDamageKiller) == TRUE) then damageKillerName = getPlayerGUID(mostDamageKiller) else damageKillerName = getCreatureName(mostDamageKiller) end end end db.executeQuery("INSERT INTO `player_deaths` (`player_id`, `time`, `level`, `killed_by`, `altkilled_by`) VALUES (" .. getPlayerGUID(cid) .. ", " .. os.time() .. ", " .. getPlayerLevel(cid) .. ", " .. db.escapeString(hitKillerName) .. ", " .. db.escapeString(damageKillerName) .. ");") local rows = db.getResult("SELECT `player_id` FROM `player_deaths` WHERE `player_id` = " .. getPlayerGUID(cid) .. ";") if(rows:getID() ~= -1) then local amount = rows:getRows(true) - config.maxDeathRecords if(amount > 0) then if(config.sqlType == DATABASE_ENGINE_SQLITE) then for i = 1, amount do db.executeQuery("DELETE FROM `player_deaths` WHERE `rowid` = (SELECT `rowid` FROM `player_deaths` WHERE `player_id` = " .. getPlayerGUID(cid) .. " ORDER BY `time` LIMIT 1);") end else db.executeQuery("DELETE FROM `player_deaths` WHERE `player_id` = " .. getPlayerGUID(cid) .. " ORDER BY `time` LIMIT " .. amount .. ";") end end end end Editado Fevereiro 21, 2013 12 anos por LucasDipic (veja o histórico de edições) >>> Baiak Slayer <<< Baiak Slayer 24h PVP 8.6 Site e IP: baiakslayer.org Informações: » 24 Horas Online » Mapa próprio da equipe Slayer (Spawns próprias) » Vocações balanceadas » Use o Cliente Baiak Slayer » 40+ Raids Automáticas » Grupo de Tutores Competentes » Excelente Suporte In-Game » 10.173+ Spawns » War System full » Sem Corrupção » Task Completa » EXP Rate: 250x Inicial (Estagiada) » Skill Rate: 30 x » Magic Rate: 15 x » Loot Rate: Própria do Servidor (Eventos Double Loot) Não perca mais tempo! Entre e divirta-se!! Citar
Postado Fevereiro 21, 2013 12 anos Esse resolve eu acho que resolve a falta da tabela time no players_death, o outro erro creature not found, eu acho que coloca if isCreature(cid) then acho que resolve mais espere algum programador mais experiente para te confirmar. ALTER TABLE `player_deaths` ADD `time` bigint(20) unsigned NOT NULL;
Postado Fevereiro 22, 2013 12 anos Autor hm.. valeu pela tentativa , mas fica foda eu tentar fazer essas coisas e não conseguir arrumar, meu ot ta on.. pode dar crash no /reload :ccc e não tenho como testar em casa .-. >>> Baiak Slayer <<< Baiak Slayer 24h PVP 8.6 Site e IP: baiakslayer.org Informações: » 24 Horas Online » Mapa próprio da equipe Slayer (Spawns próprias) » Vocações balanceadas » Use o Cliente Baiak Slayer » 40+ Raids Automáticas » Grupo de Tutores Competentes » Excelente Suporte In-Game » 10.173+ Spawns » War System full » Sem Corrupção » Task Completa » EXP Rate: 250x Inicial (Estagiada) » Skill Rate: 30 x » Magic Rate: 15 x » Loot Rate: Própria do Servidor (Eventos Double Loot) Não perca mais tempo! Entre e divirta-se!! Citar
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.