Ir para conteúdo

Featured Replies

  • Respostas 13
  • Visualizações 723
  • Created
  • Última resposta

Top Posters In This Topic

Posted Images

Postado
  • Autor

nao consegui postar em spoiler, perdao

 

 

-- The Forgotten Server Config

    -- Account manager
    accountManager = true
    namelockManager = false
    newPlayerChooseVoc = true
    newPlayerSpawnPosX = 543
    newPlayerSpawnPosY = 521
    newPlayerSpawnPosZ = 7
    newPlayerTownId = 1
    newPlayerLevel = 8
    newPlayerMagicLevel = 0
    generateAccountNumber = false

    -- 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 = 2 * 24 * 60 * 60
    blackSkullLength = 4 * 24 * 60 * 60
    dailyFragsToRedSkull = 15
    weeklyFragsToRedSkull = 30
    monthlyFragsToRedSkull = 45
    dailyFragsToBlackSkull = 25
    weeklyFragsToBlackSkull = 45
    monthlyFragsToBlackSkull = 60
    dailyFragsToBanishment = dailyFragsToRedSkull
    weeklyFragsToBanishment = weeklyFragsToRedSkull
    monthlyFragsToBanishment = monthlyFragsToRedSkull
    blackSkulledDeathHealth = 40
    blackSkulledDeathMana = 0
    useBlackSkull = true
    useFragHandler = true
    advancedFragList = false

    -- Banishments
    -- violationNameReportActionType 1 = just a report, 2 = name lock, 3 = player banishment
    -- killsBanLength works only if useBlackSkull option is disabled.
    notationsToBan = 3
    warningsToFinalBan = 4
    warningsToDeletion = 5
    banLength = 1 * 24 * 60 * 60
    killsBanLength = 1 * 24 * 60 * 60
    finalBanLength = 1 * 24 * 60 * 60
    ipBanishmentLength = 1 * 24 * 60 * 60
    broadcastBanishments = true
    maxViolationCommentSize = 200
    violationNameReportActionType = 2
    autoBanishUnknownBytes = false

    -- Battle
    -- NOTE: showHealingDamageForMonsters inheritates from showHealingDamage.
    -- loginProtectionPeriod is the famous Tibia anti-magebomb system.
    -- deathLostPercent set to nil enables manual mode.
    worldType = "pvp"
    protectionLevel = 100
    pvpTileIgnoreLevelAndVocationProtection = true
    pzLocked = 60 * 400
    huntingDuration = 30 * 1000
    criticalHitChance = 7
    criticalHitMultiplier = 1
    displayCriticalHitNotify = true
    removeWeaponAmmunition = false
    removeWeaponCharges = false
    removeRuneCharges = true
    whiteSkullTime = 10 * 60 * 1000
    noDamageToSameLookfeet = false
    showHealingDamage = true
    showHealingDamageForMonsters = true
    fieldOwnershipDuration = 5 * 1000
    stopAttackingAtExit = false
    oldConditionAccuracy = false
    loginProtectionPeriod = 10 * 1000
    deathLostPercent = 20
    stairhopDelay = 15 * 60
    pushCreatureDelay = 15 * 60
    deathContainerId = 1987
    gainExperienceColor = 215
    addManaSpentInPvPZone = true
    squareColor = 0
    allowFightback = true

    -- Connection config
    worldId = 0
    ip = "133.32.118.982"
    bindOnlyConfiguredIpAddress = false
    loginPort = 7171
    gamePort = 7172
    adminPort = 7171
    statusPort = 7171
    loginTries = 10
    retryTimeout = 5 * 1000
    loginTimeout = 60 * 1000
    maxPlayers = 500
    motd = "Bem vindos Ao colow
    displayOnOrOffAtCharlist = false
    onePlayerOnlinePerAccount = false
    allowClones = false
    serverName = "colow"
    loginMessage = "Seja bem vindo."
    statusTimeout = 5 * 60 * 1000
    replaceKickOnLogin = true
    forceSlowConnectionsToDisconnect = false
    loginOnlyWithLoginServer = false
    premiumPlayerSkipWaitList = false

    -- Database
    -- NOTE: sqlFile is used only by sqlite database, and sqlKeepAlive by mysql database.
    -- To disable sqlKeepAlive such as mysqlReadTimeout use 0 value.
    sqlType = "sqlite"
    sqlHost = "localhost"
    sqlPort = 3306
    sqlUser = "root"
    sqlPass = ""
    sqlDatabase = "theforgottenserver"
    sqlFile = "Styller.s3db"
    sqlKeepAlive = 0
    mysqlReadTimeout = 10
    mysqlWriteTimeout = 10
    encryptionType = "plain"

    -- Deathlist
    deathListEnabled = true
    deathListRequiredTime = 1 * 60 * 1000
    deathAssistCount = 0
    maxDeathRecords = 5

    -- Guilds
    ingameGuildManagement = true
    levelToFormGuild = 250
    premiumDaysToFormGuild = 0
    guildNameMinLength = 5
    guildNameMaxLength = 30

    -- Highscores
    highscoreDisplayPlayers = 10
    updateHighscoresAfterMinutes = 3

    -- Houses
    buyableAndSellableHouses = true
    houseNeedPremium = false
    bedsRequirePremium = false
    levelToBuyHouse = 100
    housesPerAccount = 0
    houseRentAsPrice = false
    housePriceAsRent = false
    housePriceEachSquare = 40000
    houseRentPeriod = "never"
    houseCleanOld = 0
    guildHalls = false

    -- Item usage
    timeBetweenActions = 200
    timeBetweenExActions = 1000
    checkCorpseOwner = true
    hotkeyAimbotEnabled = true
    maximumDoorLevel = 500

    -- Map
    -- NOTE: storeTrash costs more memory, but will perform alot faster cleaning.
    -- useHouseDataStorage usage may be found at README.
    mapName = "Soulface"
    mapAuthor = "Will"
    randomizeTiles = true
    useHouseDataStorage = false
    storeTrash = true
    cleanProtectedZones = true
    mailboxDisabledTowns = "-1"

    -- Startup
    -- NOTE: defaultPriority works only on Windows and niceLevel on *nix
    -- coresUsed are seperated by comma cores ids used by server process,
    -- default is -1, so it stays untouched (automaticaly assigned by OS).
    defaultPriority = "high"
    niceLevel = 5
    coresUsed = "-1"
    optimizeDatabaseAtStartup = true
    removePremiumOnInit = true
    confirmOutdatedVersion = false

    -- Muted buffer
    maxMessageBuffer = 4
    bufferMutedOnSpellFailure = false

    -- Miscellaneous
    -- NOTE: promptExceptionTracerErrorBox works only with precompiled support feature,
    -- called "exception tracer" (__EXCEPTION_TRACER__ flag).
    -- monsterLootMessage 0 to disable, 1 - only party, 2 - only player, 3 - party or player (like Tibia's)
    dataDirectory = "data/"
    allowChangeOutfit = true
    allowChangeColors = true
    allowChangeAddons = true
    disableOutfitsForPrivilegedPlayers = false
    bankSystem = true
    saveGlobalStorage = true
    displaySkillLevelOnAdvance = false
    spellNameInsteadOfWords = false
    emoteSpells = true
    promptExceptionTracerErrorBox = true
    storePlayerDirection = false
    monsterLootMessage = 3
    monsterLootMessageType = 25
    separateViplistPerCharacter = false

    -- Ghost mode
    ghostModeInvisibleEffect = true
    ghostModeSpellEffects = true

    -- Limits
    idleWarningTime = 59 * 60 * 1000
    idleKickTime = 60 * 60 * 1000
    expireReportsAfterReads = 1
    playerQueryDeepness = 2
    maxItemsPerPZTile = 0
    maxItemsPerHouseTile = 0

    -- Premium-related
    freePremium = false
    premiumForPromotion = false

    -- Blessings
    -- NOTE: blessingReduction* regards items/containers loss.
    -- eachBlessReduction is how much each bless reduces the experience/magic/skills loss.
    blessingOnlyPremium = true
    blessingReductionBase = 30
    blessingReductionDecreament = 5
    eachBlessReduction = 8

    -- Rates
    -- NOTE: experienceStages configuration is located in data/XML/stages.xml.
    -- rateExperienceFromPlayers 0 to disable.
    experienceStages = true
    rateExperience = 25
    rateSkill = 250
    rateMagic = 100
    rateLoot = 3
    rateSpawn = 5

    -- Monster rates
    rateMonsterHealth = 1.0
    rateMonsterMana = 1.0
    rateMonsterAttack = 1.0
    rateMonsterDefense = 1.0

    -- Experience from players
    -- NOTE: min~Threshold* set to 0 will disable the minimum threshold:
    -- player will gain experience from every lower leveled player.
    -- max~Threshold* set to 0 will disable the maximum threshold:
    -- player will gain experience from every higher leveled player.
    minLevelThresholdForKilledPlayer = 0.9
    maxLevelThresholdForKilledPlayer = 1.1

    -- Stamina
    -- NOTE: Stamina is stored in miliseconds, so seconds are multiplied by 1000.
    -- rateStaminaHits multiplies every hit done a creature, which are later
    -- multiplied by player attack speed.
    -- rateStaminaGain is divider of every logged out second, eg:
    -- 60000 / 3 = 20000 milliseconds, what gives 20 stamina seconds for 1 minute being logged off.
    -- rateStaminaThresholdGain is divider for the premium stamina.
    -- staminaRatingLimit* is in minutes.
    rateStaminaLoss = 0
    rateStaminaGain = 3
    rateStaminaThresholdGain = 12
    staminaRatingLimitTop = 41 * 60
    staminaRatingLimitBottom = 14 * 60
    rateStaminaAboveNormal = 1.5
    rateStaminaUnderNormal = 0.5
    staminaThresholdOnlyPremium = true

    -- Party
    -- NOTE: experienceShareLevelDifference is float number.
    -- experienceShareLevelDifference is highestLevel * value
        experienceShareRadiusX = 30 -- máxima distancia em X pra eles continuarem compartilhando exp
        experienceShareRadiusY = 30 -- máxima distancia em Y pra eles continuarem compartilhando exp
        experienceShareRadiusZ = 1 -- máxima distancia em Z pra eles continuarem compartilhando exp
        experienceShareLevelDifference = 1/ 3 -- diferença de nivel máxima pra eles continuarem compartilhando exp (level do mais alto multiplicado por esse valor tem que ser menor que o nível do player de level mais baixo)
        extraPartyExperienceLimit = 770 --- limite de experiencia extra
        extraPartyExperiencePercent = 200 -- porcentagem extra de experiencia por estar em party
        experienceShareActivity = 2 * 60 * 1000 --- não sei ao certo mas é ou o tempo pra poder ligar o compartilhamento de experiencia ou o tempo máximo q a exp vai ser compartilhada (sugiro não mexer)


    -- Global save
    -- NOTE: globalSaveHour means like 03:00, not that it will save every 3 hours,
    -- if you want such a system please check out data/globalevents/globalevents.xml.
    globalSaveEnabled = false
    globalSaveHour = 3
    shutdownAtGlobalSave = false
    cleanMapAtGlobalSave = false

    -- Spawns
    deSpawnRange = 2
    deSpawnRadius = 50

        healthHealingColor = 194
        manaHealingColor = 113

    -- Summons
    maxPlayerSummons = 2
    teleportAllSummons = false
    teleportPlayerSummons = false

    -- Status
    ownerName = "Conow"
    ownerEmail = ""
    url = ""
    location = "Brazil"
    displayGamemastersWithOnlineCommand = false

    -- Logs
    -- NOTE: This kind of logging does not work in GUI version.
    -- For such, please compile the software with __GUI_LOGS__ flag.
    adminLogsEnabled = false
    displayPlayersLogging = true
    prefixChannelLogs = ""
    runFile = ""
    outLogName = ""
    errorLogName = ""
    truncateLogsOnStartup = false

 

 

LOGIN.LUA

 

local config = {
    loginMessage = getConfigValue('loginMessage'),
    useFragHandler = getBooleanFromString(getConfigValue('useFragHandler'))
}

function onLogin(cid)
    local loss = getConfigValue('deathLostPercent')
    if(loss ~= nil) then
        doPlayerSetLossPercent(cid, PLAYERLOSS_EXPERIENCE, loss * 10)
    end

    local accountManager = getPlayerAccountManager(cid)
    if(accountManager == MANAGER_NONE) then
        local lastLogin, str = getPlayerLastLoginSaved(cid), config.loginMessage
        if(lastLogin > 0) then
            doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str)
            str = "Your last visit was on " .. os.date("%a %b %d %X %Y", lastLogin) .. "."
        else
            str = str .. " Please choose your outfit."
            doPlayerSendOutfitWindow(cid)
        end

        doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str)
    elseif(accountManager == MANAGER_NAMELOCK) then
        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Hello, it appears that your character has been namelocked, what would you like as your new name?")
    elseif(accountManager == MANAGER_ACCOUNT) then
        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Hello, type 'account' to manage your account and if you want to start over then type 'cancel'.")
    else
        doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Hello, type 'account' to create an account or type 'recover' to recover an account.")
    end

    if(not isPlayerGhost(cid)) then
        doSendMagicEffect(getCreaturePosition(cid), CONST_ME_TELEPORT)
    end

    registerCreatureEvent(cid, "Mail")

    registerCreatureEvent(cid, "ResetDoors")

    registerCreatureEvent(cid, "Idle")
    if(config.useFragHandler) then
        registerCreatureEvent(cid, "SkullCheck")
        registerCreatureEvent(cid, "Reward")
    end

    registerCreatureEvent(cid, "ReportBug")
    registerCreatureEvent(cid, "AdvanceSave")

registerCreatureEvent(cid, "advance")
registerCreatureEvent(cid, "SkullCheck")
    registerCreatureEvent(cid, "ReportBug")

registerCreatureEvent(cid, "lookreset")
registerCreatureEvent(cid, "deathSkill")
registerCreatureEvent(cid, "BossCorpse")
registerCreatureEvent(cid, "DeathC")
registerCreatureEvent(cid, "FimVip")
registerCreatureEvent(cid, "VipReceive")
registerCreatureEvent(cid, "PlayerKill")
    if (InitArenaScript ~= 0) then
    InitArenaScript = 1
    -- make arena rooms free
        for i = 42300, 42309 do
            setGlobalStorageValue(i, 0)
            setGlobalStorageValue(i+100, 0)
        end
    end
    -- if he did not make full arena 1 he must start from zero
    if getPlayerStorageValue(cid, 42309) < 1 then
        for i = 42300, 42309 do
            setPlayerStorageValue(cid, i, 0)
        end
    end
    -- if he did not make full arena 2 he must start from zero
    if getPlayerStorageValue(cid, 42319) < 1 then
        for i = 42310, 42319 do
            setPlayerStorageValue(cid, i, 0)
        end
    end
    -- if he did not make full arena 3 he must start from zero
    if getPlayerStorageValue(cid, 42329) < 1 then
        for i = 42320, 42329 do
            setPlayerStorageValue(cid, i, 0)
        end
    end
    if getPlayerStorageValue(cid, 42355) == -1 then
        setPlayerStorageValue(cid, 42355, 0) -- did not arena level
    end
    setPlayerStorageValue(cid, 42350, 0) -- time to kick 0
    setPlayerStorageValue(cid, 42352, 0) -- is not in arena  
return true
end

 


 

Postado
function onDeath(cid)
    if not isPlayer(cid) then return true end

        for i=1, 7 do        -- de 1 a 7 = de club até ML
          if i ~= 6 then  --se for diferente de 6 (6 é fishing)
            if getPlayerSkill(cid, i) > 12 then                -- se for maior que 12 (só cai até 10, pra proteção de bug)
              doPlayerAddSkill(cid, i, -2, true)
            end
          end
        end

return true
end


coloca assim da reload ou reabre o teu OT, e ve se funciona.

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.

Visitante
Responder

Quem Está Navegando 0

  • Nenhum usuário registrado visualizando esta página.

Conteúdo Similar

Estatísticas dos Fóruns

  • Tópicos 96.9k
  • Posts 519.6k

Informação Importante

Confirmação de Termo