Postado Outubro 8, 2014 10 anos eu abro meu ot de boa e depois de um tempo ele trava mt que desloga o char ( mas o distro nao fecha e nem da relatorio de erros ) ja tentei tirar o npc das backpacks ( pra nao dar aqueles lags quando compram muitas) ja revisei as actions do meu ot ja revisei os movements js revisei os creaturescript e nada... continua caindo o incrivel eh que quando dei /closeserver ( durante 3 horas ) o server nao caiu, dai quando dei /openserver depois de 15 min o ot caiu, eu acho que tem a ver com algum player bugado ou alguma coisa que ele faz que caia o ot. alguem que ja passou por isso pode ajudar? ( nao aparece nada no distro, apenas trava o server )
Postado Outubro 8, 2014 10 anos data/npc/lib/npc.lua poste o seu pra mim da uma olhada... E qual distro você usa tfs ou otx? Poste seu config.lua também... Editado Outubro 8, 2014 10 anos por Natanael Beckman (veja o histórico de edições)
Postado Outubro 9, 2014 10 anos Autor @Absolute, VPS 3GB RAM (LGV Host) Windows 2008 @lucasmacaca, Ja abri com 4 diferentes, acredito que nao seja o distro =/ @Natanael Beckman, - - Include the Advanced NPC System dofile(getDataDir() .. 'npc/lib/npcsystem/npcsystem.lua') function selfIdle() following = false attacking = false selfAttackCreature(0) target = 0 end function selfSayChannel(cid, message) return selfSay(message, cid, false) end function selfMoveToCreature(id) if(not id or id == 0) then return end local t = getCreaturePosition(id) if(not t.x or t.x == nil) then return end selfMoveTo(t.x, t.y, t.z) return end function getNpcDistanceToCreature(id) if(not id or id == 0) then selfIdle() return nil end local c = getCreaturePosition(id) if(not c.x or c.x == 0) then return nil end local s = getCreaturePosition(getNpcId()) if(not s.x or s.x == 0 or s.z ~= c.z) then return nil end return math.max(math.abs(s.x - c.x), math.abs(s.y - c.y)) end function doMessageCheck(message, keyword) if(type(keyword) == "table") then return table.isStrIn(keyword, message) end local a, b = message:lower():find(keyword:lower()) if(a ~= nil and b ~= nil) then return true end return false end function doNpcSellItem(cid, itemid, amount, subType, ignoreCap, inBackpacks, backpack) local amount = amount or 1 local subType = subType or 1 local ignoreCap = ignoreCap and true or false local item = 0 if(isItemStackable(itemid)) then item = doCreateItemEx(itemid, amount) if(doPlayerAddItemEx(cid, item, ignoreCap) ~= RETURNVALUE_NOERROR) then return 0, 0 end return amount, 0 end local a = 0 if(inBackpacks) then local container = doCreateItemEx(backpack, 1) local b = 1 for i = 1, amount do item = doAddContainerItem(container, itemid, subType) if(itemid == ITEM_PARCEL) then doAddContainerItem(item, ITEM_LABEL) end if(isInArray({(getContainerCapById(backpack) * b), amount}, i)) then if(doPlayerAddItemEx(cid, container, ignoreCap) ~= RETURNVALUE_NOERROR) then b = b - 1 break end a = i if(amount > i) then container = doCreateItemEx(backpack, 1) b = b + 1 end end end return a, b end for i = 1, amount do item = doCreateItemEx(itemid, subType) if(itemid == ITEM_PARCEL) then doAddContainerItem(item, ITEM_LABEL) end if(doPlayerAddItemEx(cid, item, ignoreCap) ~= RETURNVALUE_NOERROR) then break end a = i end return a, 0 end function doRemoveItemIdFromPos (id, n, position) local thing = getThingFromPos({x = position.x, y = position.y, z = position.z, stackpos = 1}) if(thing.itemid == id) then doRemoveItem(thing.uid, n) return true end return false end function getNpcName() return getCreatureName(getNpcId()) end function getNpcPos() return getCreaturePosition(getNpcId()) end function selfGetPosition() local t = getNpcPos() return t.x, t.y, t.z end msgcontains = doMessageCheck moveToPosition = selfMoveTo moveToCreature = selfMoveToCreature selfMoveToPosition = selfMoveTo selfGotoIdle = selfIdle isPlayerPremiumCallback = isPremium doPosRemoveItem = doRemoveItemIdFromPos doNpcBuyItem = doPlayerRemoveItem doNpcSetCreatureFocus = selfFocus getNpcCid = getNpcId getDistanceTo = getNpcDistanceTo getDistanceToCreature = getNpcDistanceToCreature Config - The Forgotten Server Config -- Account manager accountManager = "yes" namelockManager = "no" newPlayerChooseVoc = "yes" newPlayerSpawnPosX = 63 newPlayerSpawnPosY = 198 newPlayerSpawnPosZ = 7 newPlayerTownId = 1 newPlayerLevel = 10 newPlayerMagicLevel = 0 generateAccountNumber = "no" -- 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 = 3 * 24 * 60 * 60 dailyFragsToRedSkull = 10 weeklyFragsToRedSkull = 10000 monthlyFragsToRedSkull = 100000 dailyFragsToBlackSkull = dailyFragsToRedSkull weeklyFragsToBlackSkull = weeklyFragsToRedSkull monthlyFragsToBlackSkull = monthlyFragsToRedSkull dailyFragsToBanishment = dailyFragsToRedSkull weeklyFragsToBanishment = weeklyFragsToRedSkull monthlyFragsToBanishment = monthlyFragsToRedSkull blackSkulledDeathHealth = 100 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 = 30 * 24 * 60 * 60 killsBanLength = 1 * 60 * 60 finalBanLength = 30 * 24 * 60 * 60 ipBanishmentLength = 1 * 24 * 60 * 60 broadcastBanishments = false 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 = 1 pvpTileIgnoreLevelAndVocationProtection = true pzLocked = 30 * 1000 huntingDuration = 60 * 1000 criticalHitChance = 100 criticalHitMultiplier = 1 displayCriticalHitNotify = true removeWeaponAmmunition = false removeWeaponCharges = false removeRuneCharges = "no" whiteSkullTime = 1 * 60 * 1000 noDamageToSameLookfeet = false showHealingDamage = true showHealingDamageForMonsters = false fieldOwnershipDuration = 5 * 1000 stopAttackingAtExit = false oldConditionAccuracy = false loginProtectionPeriod = 10 * 1000 deathLostPercent = 10 stairhopDelay = 0 * 0 pushCreatureDelay = 1 * 1000 deathContainerId = 1987 gainExperienceColor = 215 addManaSpentInPvPZone = true squareColor = 0 allowFightback = true healthHealingColor = 35 manaHealingColor = 191 -- Connection config worldId = 0 ip = "holiday-sv1.servegame.com" bindOnlyConfiguredIpAddress = false loginPort = 7171 gamePort = 7172 adminPort = 7171 statusPort = 7171 loginTries = 8 retryTimeout = 1 * 1000 loginTimeout = 60 * 1000 maxPlayers = 200 motd = "Bem vindo" displayOnOrOffAtCharlist = false onePlayerOnlinePerAccount = true allowClones = false serverName = "24h" loginMessage = "bem vindo." statusTimeout = 1 * 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 = "Alissow" sqlFile = "schemas+Database/Alissow.s3db" sqlKeepAlive = 0 mysqlReadTimeout = 10 mysqlWriteTimeout = 10 encryptionType = "plain" -- Deathlist deathListEnabled = true deathListRequiredTime = 1 * 60 * 1000 deathAssistCount = 19 maxDeathRecords = 5 -- Guilds ingameGuildManagement = true levelToFormGuild = 8 premiumDaysToFormGuild = 0 guildNameMinLength = 4 guildNameMaxLength = 20 -- Highscores highscoreDisplayPlayers = 100 updateHighscoresAfterMinutes = 2 -- Houses buyableAndSellableHouses = true houseNeedPremium = false bedsRequirePremium = false levelToBuyHouse = 1 housesPerAccount = 0 houseRentAsPrice = false housePriceAsRent = false housePriceEachSquare = 100000 houseRentPeriod = "never" houseCleanOld = 0 guildHalls = false -- Item usage timeBetweenActions = 200 timeBetweenExActions = 1000 checkCorpseOwner = true hotkeyAimbotEnabled = true maximumDoorLevel = 40000 -- Map -- NOTE: storeTrash costs more memory, but will perform alot faster cleaning. -- useHouseDataStorage usage may be found at README. mapName = "Baiak Yurots" mapAuthor = "Baiak Lula" 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 = 10 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 = 2 monsterLootMessageType = 25 separateViplistPerCharacter = false addonsOnlyPremium = false -- Ghost mode ghostModeInvisibleEffect = true ghostModeSpellEffects = true -- Limits idleWarningTime = 559 * 60 * 1000 idleKickTime = 600 * 60 * 1000 expireReportsAfterReads = 1 playerQueryDeepness = 2 maxItemsPerPZTile = 0 maxItemsPerHouseTile = 0 -- Premium-related freePremium = false premiumForPromotion = true -- Blessings -- NOTE: blessingReduction* regards items/containers loss. -- eachBlessReduction is how much each bless reduces the experience/magic/skills loss. blessingOnlyPremium = false blessingReductionBase = 30 blessingReductionDecreament = 5 eachBlessReduction = 8 -- Rates -- NOTE: experienceStages configuration is located in data/XML/stages.xml. -- rateExperienceFromPlayers 0 to disable. experienceStages = "yes" rateExperience = 5000 rateExperienceFromPlayers = 0 rateSkill = 500 rateMagic = 300 rateLoot = 10 rateSpawn = 4 -- Monster rates rateMonsterHealth = 1.2 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 = 3000 rateStaminaThresholdGain = 12000 staminaRatingLimitTop = 40 * 60 staminaRatingLimitBottom = 14 * 60 rateStaminaAboveNormal = 2.0 rateStaminaUnderNormal = 0.5 staminaThresholdOnlyPremium = true -- Party -- NOTE: experienceShareLevelDifference is float number. -- experienceShareLevelDifference is highestLevel * value experienceShareRadiusX = 30 experienceShareRadiusY = 30 experienceShareRadiusZ = 1 experienceShareLevelDifference = 2 / 3 extraPartyExperienceLimit = 20 extraPartyExperiencePercent = 5 experienceShareActivity = 2 * 60 * 1000 -- 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 = 8 shutdownAtGlobalSave = true cleanMapAtGlobalSave = false -- Spawns deSpawnRange = 2 deSpawnRadius = 50 -- Summons maxPlayerSummons = 1 teleportAllSummons = true teleportPlayerSummons = false -- Status ownerName = "{GOD} Bryan" ownerEmail = "@otland.net" url = "http://otland.net/" location = "Europe" 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
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.