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

Some players can't die

SaxtoN

New Member
Joined
Mar 1, 2010
Messages
81
Reaction score
0
Well, some of my players can't die.

When they are getting Pked they get 0 health points and no one can target them they are not even in their battle list.
 
That should be a problem of playerdeath.lua

Go to data/creaturescripts/scripts and open the file "playerdeath.lua"
in there delete all and copy this:
PHP:
function onDeath(cid, corpse, deathList)

local strings = {""}
local t, position = 1, 1

local deathType = "killed"
local toSlain, toCrushed, toEliminated = 3, 9, 15

        if #deathList >= toSlain and #deathList < toCrushed then
                deathType = "slain"
        elseif #deathList >= toCrushed and #deathList < toEliminated then
                deathType = "crushed"
        elseif #deathList >= toEliminated then
                deathType = "eliminated"
        end

        for _, pid in ipairs(deathList) do
                if isCreature(pid) == true then
                        strings[position] = t == 1 and "" or strings[position] .. ", "
                        strings[position] = strings[position] .. getCreatureName(pid) .. ""
                        t = t + 1
                else
                        strings[position] = t == 1 and "" or strings[position] .. ", "
                        strings[position] = strings[position] .."a field item"
                        t = t + 1
                end
        end

        for i, str in ipairs(strings) do
                if(str:sub(str:len()) ~= ",") then
                        str = str .. "."
                end

                msg = getCreatureName(cid) .. " was " .. deathType .. " at level " .. getPlayerLevel(cid) .. " by " .. str
        end

        for _, oid in ipairs(getPlayersOnline()) do
                doPlayerSendChannelMessage(oid, "Death channel", msg, TALKTYPE_CHANNEL_O, CHANNEL_DEATH)
        end
        return true
end


rep+ me if I helped you ^^
 
Nope still same thing :(

There is just some players who get this to.

It's like when im killing this players hes health bar removes and everything can't see hes skull name etc.


Here is the console.

 
you must add those to your phpmyadmin
Code:
ALTER TABLE `guilds` 
ADD `invited_to` INT( 11 ) NOT NULL ,
ADD `invited_by` INT( 11 ) NOT NULL ,
ADD `in_war_with` INT( 11 ) NOT NULL ,
ADD `kills` INT( 11 ) NOT NULL ,
ADD `show` SMALLINT( 1 ) NOT NULL ,
ADD `war_time` INT( 11 ) NOT NULL ;
Code:
 CREATE TABLE `deaths_in_wars` (
`guild_id` INT( 11 ) NOT NULL ,
`player_id` INT( 11 ) NOT NULL ,
`killer_guild` INT( 11 ) NOT NULL ,
`killer` INT( 11 ) NOT NULL ,
`date` INT( 11 ) NOT NULL ,
`result1` INT( 11 ) NOT NULL ,
`result2` INT( 11 ) NOT NULL 
) ENGINE = MYISAM ;
Code:
  UPDATE `guilds` SET `invited_to` = 0, `invited_by` = 0, `in_war_with` = 0, `kills` = 0, `show` = 0, `war_time` = 0 WHERE `id` > 0;
guild war system !
 
Code:
ALTER TABLE "guilds"
ADD (   "invited_to" INTEGER NOT NULL,
	"invited_by" INTEGER NOT NULL,
	"in_war_with" INTEGER NOT NULL,
	"kills" INTEGER NOT NULL,
	"show" TINYINT NOT NULL,
	"war_time" INTEGER NOT NULL);

CREATE TABLE "deaths_in_wars" (
	"guild_id" INTEGER NOT NULL,
	"player_id" INTEGER NOT NULL,
	"killer_guild" INTEGER NOT NULL,
	"killer" INTEGER NOT NULL,
	"date" INTEGER NOT NULL,
	"result1" INTEGER NOT NULL,
	"result2" INTEGER NOT NULL
);

UPDATE "guilds" SET "invited_to" = 0, "invited_by" = 0, "in_war_with" = 0, "kills" = 0, "show" = 0, "war_time" = 0 WHERE "id" > 0;
 
Back
Top