Ir para conteúdo

[Encerrado] RedSkull ?


SilvaPereira

Posts Recomendados

eu tenho uma duvida , meu redskull nao esta funcionando ...

esse e o meu config.lua ( obs: ot 8.60 )

 

 

redSkullLength = 10 * 24 * 60 * 60

blackSkullLength = 20 * 24 * 60 * 60

dailyFragsToRedSkull = 5

weeklyFragsToRedSkull = 10

monthlyFragsToRedSkull = 20

dailyFragsToBlackSkull = dailyFragsToRedSkull

weeklyFragsToBlackSkull = weeklyFragsToRedSkull

monthlyFragsToBlackSkull = monthlyFragsToRedSkull

dailyFragsToBanishment = dailyFragsToRedSkull

weeklyFragsToBanishment = weeklyFragsToRedSkull

monthlyFragsToBanishment = monthlyFragsToRedSkull

blackSkulledDeathHealth = 40

blackSkulledDeathMana = 0

useBlackSkull = true

useFragHandler = true

advancedFragList = true

 

e esse esta no talkactions/frags

 

 

local config = {

useFragHandler = getBooleanFromString(getConfigValue('useFragHandler')),

advancedFragList = getBooleanFromString(getConfigValue('advancedFragList'))

}

function onSay(cid, words, param, channel)

if(not config.useFragHandler) then

return FALSE

end

local time = os.time()

local times = {today = (time - 86400), week = (time - (7 * 86400))}

local contents, result = {day = {}, week = {}, month = {}}, db.getResult("SELECT `pd`.`date`, `pd`.`level`, `p`.`name` FROM `player_killers` pk LEFT JOIN `killers` k ON `pk`.`kill_id` = `k`.`id` LEFT JOIN `player_deaths` pd ON `k`.`death_id` = `pd`.`id` LEFT JOIN `players` p ON `pd`.`player_id` = `p`.`id` WHERE `pk`.`player_id` = " .. getPlayerGUID(cid) .. " AND `k`.`unjustified` = 1 AND `pd`.`date` >= " .. (time - (30 * 86400)) .. " ORDER BY `pd`.`date` DESC")

if(result:getID() ~= -1) then

repeat

local content = {

name = result:getDataString("name"),

level = result:getDataInt("level"),

date = result:getDataInt("date")

}

if(content.date > times.today) then

table.insert(contents.day, content)

elseif(content.date > times.week) then

table.insert(contents.week, content)

else

table.insert(contents.month, content)

end

until not result:next()

result:free()

end

local size = {

day = table.maxn(contents.day),

week = table.maxn(contents.week),

month = table.maxn(contents.month)

}

if(config.advancedFragList) then

local result = "Frags gained today: " .. size.day .. "."

if(size.day > 0) then

for _, content in ipairs(contents.day) do

result = result .. "\n* " .. os.date("%d %B %Y %X at ", content.date) .. content.name .. " on level " .. content.level

end

result = result .. "\n"

end

result = result .. "\nFrags gained this week: " .. (size.day + size.week) .. "."

if(size.week > 0) then

for _, content in ipairs(contents.week) do

result = result .. "\n* " .. os.date("%d %B %Y %X at ", content.date) .. content.name .. " on level " .. content.level

end

result = result .. "\n"

end

result = result .. "\nFrags gained this month: " .. (size.day + size.week + size.month) .. "."

if(size.month > 0) then

for _, content in ipairs(contents.month) do

result = result .. "\n* " .. os.date("%d %B %Y %X at ", content.date) .. content.name .. " on level " .. content.level

end

result = result .. "\n"

end

local skullEnd = getPlayerSkullEnd(cid)

if(skullEnd > 0) then

result = result .. "\nYour " .. (getCreatureSkullType(cid) == SKULL_RED and "red" or "black") .. " skull will expire at " .. os.date("%d %B %Y %X", skullEnd)

end

doPlayerPopupFYI(cid, result)

else

doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You currently have " .. size.day .. " frags today, " .. (size.day + size.week) .. " this week and " .. (size.day + size.week + size.month) .. " this month.")

if(size.day > 0) then

doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Last frag at " .. os.date("%d %B %Y %X", contents.day[1].date) .. " on level " .. contents.day[1].level .. " (" .. contents.day[1].name .. ").")

end

local skullEnd = getPlayerSkullEnd(cid)

if(skullEnd > 0) then

doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Your " .. (getCreatureSkullType(cid) == SKULL_RED and "red" or "black") .. " skull will expire at " .. os.date("%d %B %Y %X", skullEnd))

end

end

return TRUE

end

 

nao sei o que fazer pra que o redskull no meu ot funcione , por mais que eu mate 50 pessoas ele nao pega 1 injust =/

alguem pode ajudar ?

Editado por SilvaPereira
Link para o comentário
Compartilhar em outros sites

Primeiramente, uns spoilers iam bem neh parça??

2º não manjo muito de scripts mas posso tentar sanar sua duvida.

Creio que não seja em talkactions o seu problema, deve haver algum script na pasta "CreatureScripts" do seu ot que faz com que não pegue red...

Link para o comentário
Compartilhar em outros sites

Adiciona essa linha entre useBlackSkull = true e useFragHandler = true

 

Vai ficar assim

useBlackSkull = true

useRedSkull = true

useBlackSkull = true

 

Editado por ddk
Link para o comentário
Compartilhar em outros sites

nao sei fazer "spoiler" mals ai =/

ddk , usando o useRedSkull , agora ele ta pegando injust , mas ainda continua nao pegando redskull e nem black skull =/

Meu config.lua ta assim:

 

 

accountManager = true

namelockManager = true

newPlayerChooseVoc = true

newPlayerSpawnPosX = 32369

newPlayerSpawnPosY = 32241

newPlayerSpawnPosZ = 7

newPlayerTownId = 2

newPlayerLevel = 8

newPlayerMagicLevel = 0

generateAccountNumber = true

 

redSkullLength = 10 * 24 * 60 * 60

blackSkullLength = 20 * 24 * 60 * 60

dailyFragsToRedSkull = 3

weeklyFragsToRedSkull = 10

monthlyFragsToRedSkull = 20

dailyFragsToBlackSkull = dailyFragsToRedSkull

weeklyFragsToBlackSkull = weeklyFragsToRedSkull

monthlyFragsToBlackSkull = monthlyFragsToRedSkull

dailyFragsToBanishment = dailyFragsToRedSkull

weeklyFragsToBanishment = weeklyFragsToRedSkull

monthlyFragsToBanishment = monthlyFragsToRedSkull

blackSkulledDeathHealth = 40

blackSkulledDeathMana = 0

useBlackSkull = true

useRedSkull = true

useFragHandler = true

advancedFragList = true

 

notationsToBan = 3

warningsToFinalBan = 4

warningsToDeletion = 5

banLength = 3 * 24 * 60 * 60

killsBanLength = 2 * 24 * 60 * 60

finalBanLength = 7 * 24 * 60 * 60

ipBanishmentLength = 7 * 24 * 60 * 60

broadcastBanishments = false

maxViolationCommentSize = 200

violationNameReportActionType = 2

autoBanishUnknownBytes = true

 

worldType = "pvp"

protectionLevel = 8

pvpTileIgnoreLevelAndVocationProtection = true

pzLocked = 30 * 500

huntingDuration = 60 * 1000

criticalHitChance = 7

criticalHitMultiplier = 1

displayCriticalHitNotify = false

removeWeaponAmmunition = true

removeWeaponCharges = true

removeRuneCharges = true

whiteSkullTime = 15 * 60 * 1000

noDamageToSameLookfeet = false

showHealingDamage = false

showHealingDamageForMonsters = false

fieldOwnershipDuration = 5 * 1000

stopAttackingAtExit = true

oldConditionAccuracy = false

loginProtectionPeriod = 10 * 1000

deathLostPercent = 10

stairhopDelay = 2 * 1000

pushCreatureDelay = 2 * 1000

deathContainerId = 1987

gainExperienceColor = 215

addManaSpentInPvPZone = true

squareColor = 0

allowFightback = true

 

worldId = 0

ip = "dreambeta.servegame.com"

bindOnlyConfiguredIpAddress = false

loginPort = 7171

gamePort = 7172

adminPort = 7171

statusPort = 7171

loginTries = 3

retryTimeout = 5 * 1000

loginTimeout = 60 * 1000

maxPlayers = 300

motd = "Bem Vindo ao Server"

displayOnOrOffAtCharlist = true

onePlayerOnlinePerAccount = true

allowClones = false

serverName = "Dreameater"

loginMessage = "Bem Vindo!"

statusTimeout = 5 * 60 * 1000

replaceKickOnLogin = true

forceSlowConnectionsToDisconnect = false

loginOnlyWithLoginServer = false

premiumPlayerSkipWaitList = false

 

sqlType = "sqlite"

sqlHost = "localhost"

sqlPort = 3306

sqlUser = "root"

sqlPass = ""

sqlDatabase = "realserver"

sqlFile = "realserver.s3db"

sqlKeepAlive = 0

mysqlReadTimeout = 10

mysqlWriteTimeout = 10

encryptionType = "plain"

 

deathListEnabled = false

deathListRequiredTime = 2 * 60 * 1000

deathAssistCount = 19

maxDeathRecords = 5

 

ingameGuildManagement = true

levelToFormGuild = 25

premiumDaysToFormGuild = 0

guildNameMinLength = 4

guildNameMaxLength = 20

 

highscoreDisplayPlayers = 10

updateHighscoresAfterMinutes = 15

 

buyableAndSellableHouses = true

houseNeedPremium = false

bedsRequirePremium = false

levelToBuyHouse = 50

housesPerAccount = 0

houseRentAsPrice = false

housePriceAsRent = false

housePriceEachSquare = 5000

houseRentPeriod = "never"

houseCleanOld = 0

guildHalls = true

 

timeBetweenActions = 200

timeBetweenExActions = 1000

checkCorpseOwner = true

hotkeyAimbotEnabled = true

maximumDoorLevel = 500

 

mapName = "realmap"

mapAuthor = "Real Team"

randomizeTiles = true

useHouseDataStorage = false

storeTrash = true

cleanProtectedZones = true

mailboxDisabledTowns = "-1"

 

defaultPriority = "high"

niceLevel = 5

coresUsed = "-1"

optimizeDatabaseAtStartup = true

removePremiumOnInit = false

confirmOutdatedVersion = false

 

maxMessageBuffer = 4

bufferMutedOnSpellFailure = false

 

dataDirectory = "data/"

allowChangeOutfit = true

allowChangeColors = true

allowChangeAddons = true

disableOutfitsForPrivilegedPlayers = false

bankSystem = false

saveGlobalStorage = true

displaySkillLevelOnAdvance = false

spellNameInsteadOfWords = false

emoteSpells = false

promptExceptionTracerErrorBox = true

storePlayerDirection = false

monsterLootMessage = 3

monsterLootMessageType = 25

separateViplistPerCharacter = false

 

ghostModeInvisibleEffect = true

ghostModeSpellEffects = true

 

idleWarningTime = 14 * 60 * 1000

idleKickTime = 15 * 60 * 1000

expireReportsAfterReads = 1

playerQueryDeepness = 2

maxItemsPerPZTile = 0

maxItemsPerHouseTile = 0

 

freePremium = false

premiumForPromotion = false

 

blessingOnlyPremium = false

blessingReductionBase = 30

blessingReductionDecreament = 5

eachBlessReduction = 8

 

experienceStages = true

rateExperience = 50.0

rateExperienceFromPlayers = 0

rateSkill = 40.0

rateMagic = 13.0

rateLoot = 1

rateSpawn = 2

 

rateMonsterHealth = 1.0

rateMonsterMana = 1.0

rateMonsterAttack = 1.0

rateMonsterDefense = 1.0

 

minLevelThresholdForKilledPlayer = 0.9

maxLevelThresholdForKilledPlayer = 1.1

 

rateStaminaLoss = 3

rateStaminaGain = 1

rateStaminaThresholdGain = 12

staminaRatingLimitTop = 41 * 60

staminaRatingLimitBottom = 14 * 60

rateStaminaAboveNormal = 1.5

rateStaminaUnderNormal = 0.5

staminaThresholdOnlyPremium = false

 

experienceShareRadiusX = 30

experienceShareRadiusY = 30

experienceShareRadiusZ = 1

experienceShareLevelDifference = 2 / 3

extraPartyExperienceLimit = 20

extraPartyExperiencePercent = 5

experienceShareActivity = 2 * 60 * 1000

 

globalSaveEnabled = true

globalSaveHour = 8

shutdownAtGlobalSave = false

cleanMapAtGlobalSave = false

 

deSpawnRange = 2

deSpawnRadius = 50

 

maxPlayerSummons = 2

teleportAllSummons = false

teleportPlayerSummons = false

 

ownerName = "Doohrush"

ownerEmail = "doohz_rush@hotmail.com"

url = "http://XTibia.com/"

location = "Brazil"

displayGamemastersWithOnlineCommand = true

 

adminLogsEnabled = false

displayPlayersLogging = true

prefixChannelLogs = ""

runFile = ""

outLogName = ""

errorLogName = ""

truncateLogsOnStartup = false

Editado por SilvaPereira
Link para o comentário
Compartilhar em outros sites

mkbrabsolute

 

o meu escript seria a pasta frags em talkactions/scripts ??

 

se for esta aki \/ ( obs: mais uma vez pesso desculpa , pois nao sei usar o "spoiler" )

 

 

local config = {

useFragHandler = getBooleanFromString(getConfigValue('useFragHandler')),

advancedFragList = getBooleanFromString(getConfigValue('advancedFragList'))

}

function onSay(cid, words, param, channel)

if(not config.useFragHandler) then

return TRUE

end

local time = os.time()

local times = {today = (time - 86400), week = (time - (7 * 86400))}

local contents, result = {day = {}, week = {}, month = {}}, db.getResult("SELECT `pd`.`date`, `pd`.`level`, `p`.`name` FROM `player_killers` pk LEFT JOIN `killers` k ON `pk`.`kill_id` = `k`.`id` LEFT JOIN `player_deaths` pd ON `k`.`death_id` = `pd`.`id` LEFT JOIN `players` p ON `pd`.`player_id` = `p`.`id` WHERE `pk`.`player_id` = " .. getPlayerGUID(cid) .. " AND `k`.`unjustified` = 1 AND `pd`.`date` >= " .. (time - (30 * 86400)) .. " ORDER BY `pd`.`date` DESC")

if(result:getID() ~= -1) then

repeat

local content = {

name = result:getDataString("name"),

level = result:getDataInt("level"),

date = result:getDataInt("date")

}

if(content.date > times.today) then

table.insert(contents.day, content)

elseif(content.date > times.week) then

table.insert(contents.week, content)

else

table.insert(contents.month, content)

end

until not result:next()

result:free()

end

local size = {

day = table.maxn(contents.day),

week = table.maxn(contents.week),

month = table.maxn(contents.month)

}

if(config.advancedFragList) then

local result = "Frags gained today: " .. size.day .. "."

if(size.day > 0) then

for _, content in ipairs(contents.day) do

result = result .. "\n* " .. os.date("%d %B %Y %X at ", content.date) .. content.name .. " on level " .. content.level

end

result = result .. "\n"

end

result = result .. "\nFrags gained this week: " .. (size.day + size.week) .. "."

if(size.week > 0) then

for _, content in ipairs(contents.week) do

result = result .. "\n* " .. os.date("%d %B %Y %X at ", content.date) .. content.name .. " on level " .. content.level

end

result = result .. "\n"

end

result = result .. "\nFrags gained this month: " .. (size.day + size.week + size.month) .. "."

if(size.month > 0) then

for _, content in ipairs(contents.month) do

result = result .. "\n* " .. os.date("%d %B %Y %X at ", content.date) .. content.name .. " on level " .. content.level

end

result = result .. "\n"

end

local skullEnd = getPlayerSkullEnd(cid)

if(skullEnd > 0) then

result = result .. "\nYour " .. (getCreatureSkullType(cid) == SKULL_RED and "red" or "black") .. " skull will expire at " .. os.date("%d %B %Y %X", skullEnd)

end

doPlayerPopupFYI(cid, result)

else

doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "You currently have " .. size.day .. " frags today, " .. (size.day + size.week) .. " this week and " .. (size.day + size.week + size.month) .. " this month.")

if(size.day > 0) then

doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Last frag at " .. os.date("%d %B %Y %X", contents.day[1].date) .. " on level " .. contents.day[1].level .. " (" .. contents.day[1].name .. ").")

end

local skullEnd = getPlayerSkullEnd(cid)

if(skullEnd > 0) then

doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Your " .. (getCreatureSkullType(cid) == SKULL_RED and "red" or "black") .. " skull will expire at " .. os.date("%d %B %Y %X", skullEnd))

end

end

return TRUE

end

Editado por SilvaPereira
Link para o comentário
Compartilhar em outros sites

  • 5 years later...
A questão neste tópico de suporte foi encerrada por falta de respostas. Este tópico está fechado e foi movido para Suporte - Tópicos Sem Resposta.

+ Caso a dúvida não tenha sido resolvida você poderá criar outro tópico solicitando ajuda.
* Lembre-se que é permitido dar UP no tópico a cada 24 horas para assim o destacar e manter movimentado.
Link para o comentário
Compartilhar em outros sites

Visitante
Este tópico está impedido de receber novos posts.
×
×
  • Criar Novo...