function Player:addUnjustifiedDead(attacked)
if getPlayerFlagValue(self, PlayerFlag_NotGainInFight) or attacked == self or Game.getWorldType() == WORLD_TYPE_PVP_ENFORCED then
return
end
-- storage value to prevent a frag
if attacked:getStorageValue(123456) == 1 then
return
end
self:sendTextMessage(MESSAGE_EVENT_ADVANCE, "Warning! The murder of " .. attacked:getName() .. " was not justified.")
local skullTicks = configManager.getNumber(configKeys.FRAG_TIME)
if (self:getSkull() != SKULL_BLACK) then
if (configManager.getNumber(configKeys.KILLS_TO_BLACK)) != 0 and (skullTicks > (configManager.getNumber(configKeys.KILLS_TO_BLACK) - 1) * (configManager.getNumber(configKeys.FRAG_TIME))) then
self:setSkull(SKULL_BLACK)
elseif self:getSkull() != SKULL_RED and configManager.getNumber(configKeys.KILLS_TO_RED) != 0 and skullTicks > (configManager.getNumber(configKeys.KILLS_TO_RED) - 1) * configManager.getNumber(configKeys.FRAG_TIME) then
self:setSkull(SKULL_RED)
end
end
return
end