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

Red Skull dont work.

Sifrid

New Member
Joined
Oct 27, 2008
Messages
42
Reaction score
0
Location
Venezuela
This is my Config.lua

-- Unjustified kills
-- NOTE: *Banishment and *BlackSkull variables are >summed up<
-- (dailyFragsToRedSkull + dailyFragsToBanishment) with their
-- *RedSkull equivalents.
-- Auto banishing works only if useBlackSkull set to negative.
-- advancedFragList is not advised if you use huge frags
-- requirements.
redSkullLength = 7 * 24 * 60 * 60
blackSkullLength = 10 * 24 * 60 * 60
dailyFragsToRedSkull = 2
weeklyFragsToRedSkull = 5
monthlyFragsToRedSkull = 7
dailyFragsToBlackSkull = dailyFragsToRedSkull
weeklyFragsToBlackSkull = weeklyFragsToRedSkull
monthlyFragsToBlackSkull = monthlyFragsToRedSkull
dailyFragsToBanishment = dailyFragsToRedSkull
weeklyFragsToBanishment = weeklyFragsToRedSkull
monthlyFragsToBanishment = monthlyFragsToRedSkull
blackSkulledDeathHealth = 40
blackSkulledDeathMana = 0
useBlackSkull = true
useFragHandler = true
advancedFragList = true

I kill with a character 10 players injust and dont get red.. I have 1 year having this problem. I need a solution please ppl!
 
change

Code:
dailyFragsToBlackSkull = dailyFragsToRedSkull
weeklyFragsToBlackSkull = weeklyFragsToRedSkull
monthlyFragsToBlackSkull = monthlyFragsToRedSkull
dailyFragsToBanishment = dailyFragsToRedSkull
weeklyFragsToBanishment = weeklyFragsToRedSkull
monthlyFragsToBanishment = monthlyFragsToRedSkull

To For Ex:

Code:
dailyFragsToBlackSkull = 20
weeklyFragsToBlackSkull = 30
monthlyFragsToBlackSkull = 50
dailyFragsToBanishment = 25
weeklyFragsToBanishment = 35
monthlyFragsToBanishment = 55

Then it will work Becouse with that you made black skull=red skull then when he get redskull it apear as black skull

Sorry for my bad english
 
Try this just for testing purposes (I suppose you I'll test this config in a private server, without players)

Lua:
-- Unjustified kills
-- NOTE: *Banishment and *BlackSkull variables are >summed up<
-- (dailyFragsToRedSkull + dailyFragsToBanishment) with their
-- *RedSkull equivalents.
-- Auto banishing works only if useBlackSkull set to negative.
-- advancedFragList is not advised if you use huge frags
-- requirements.
redSkullLength = 7 * 24 * 60 * 60
blackSkullLength = 10 * 24 * 60 * 60
dailyFragsToRedSkull = 1
weeklyFragsToRedSkull = 2
monthlyFragsToRedSkull = 3
dailyFragsToBlackSkull = 4
weeklyFragsToBlackSkull = 5
monthlyFragsToBlackSkull = 6
dailyFragsToBanishment = 7
weeklyFragsToBanishment = 8
monthlyFragsToBanishment = 9
blackSkulledDeathHealth = 40
blackSkulledDeathMana = 0
useBlackSkull = true
useFragHandler = true
advancedFragList = false

If it works, change other values as pleased
 
Aaaaaaaaffffffffffffffff..... Get RedSkull with a frag. I find the bug. The problem is registering the frag.. I'm killing ppl.. But the frags dont register in "Player_death"/"killers" What i can do?
 
Try this:

creaturescripts/scripts/playerdeath.lua

Lua:
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.query("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

creaturescripts/scripts/login.lua

Lua:
registerCreatureEvent(cid, "PlayerDeath")

creaturescripts.xml

Lua:
<event type="death" name="PlayerDeath" event="script" value="playerdeath.lua"/>
 
what kind of weird server are you using that doesn't register deaths? if useFragHandler is true, it should be working in 0.3+
 
Back
Top