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

Search results

  1. B

    Lua NPC that attack skulleds

    Hello, I am having problem with a script I made. local config = { maxDistance = 20, followTimeout = 10, range = 5, damage = {min = 500, max = 1000}, messages = { onSpot = "We do not tolerate people like you, %s", onFlee = "I will catch you next time!", onTimeout =...
  2. B

    /attr

    Why the "/attr" don't works properly on TFS 0.4? It doesn't edit attack, defense, name, description of items... I tried: /attr attack 80 /attr attack, 80 /attr set attack, 80 /attr set attack 80 And nothing... Can someone help me?
  3. B

    Lua doMoveCreature

    This function moves creatures upon items that block path, walls and etcetera... there is a way to don't move the creature if the is a wall or item blocking its path?
  4. B

    Lua Patterns Tutorial

    Can someone recommend a good LUA patterns tutorial? How to use patterns in string.match and string.find. I know the meaning of all symbols, as: "%d+" or "%u". But I need some tips how to use them correctly. eg: How to select all four numbers in this string. local num = "30 50 60 90"
  5. B

    Lua How to short this script.

    Hello, people. ^_^ I've found a script that I made a time ago and I tried to use for and tables to shorten it. It's a smithing system where you use a hammer in some stacked items to create another item, example: Magic Sword. I want to use a recipes table and for to short the script, but I'm...
  6. B

    TFS 0.4 - The NPCs don't say nothing in Farewell

    Help with this. In the TFS 0.4, none of NPCs say nothing when I say bye.
  7. B

    Movements crashing server. Rep+ for solution.

    Hello. I got TheForgottenServer 0.3.6pl1 and if I create an item with a movement script assigned and this item appears on his slot, the server crashes. I tried to make the movement script in Mods and don't got a fix. There is a way (source edition or lua code) to fix that? I rep+ anyone that...
  8. B

    Lua Problems with onEquip

    Hello! I am having problems with the function onEquip, see this LUA script: local r = { [2467] = { slot = CONST_SLOT_ARMOR, } } function onEquip(cid, item, slot) local k = r[item.itemid] if(k and slot == k.slot) then setCreatureMaxHealth(cid, getCreatureMaxHealth(cid)+100) end...
  9. B

    NPCs and Stackable Items

    Hi ^_^. My NPC's don't buy stackable items, like Potions, Runes and Creature Products. When I try to sell, for example, 100 sandcrawler shell, a cancel message is shown: You do not have this object Someone know how I can solve this problem? Doesn't matter if the fix is in sources or in LUA...
  10. B

    Single Focus and NPC Channel

    Hello, Is the a way to use "single focus" system and the NPC Channel together? If yes, how can I do this? EDITED - When I say "single focus", it's mean "NPCs talking with one player a time"
  11. B

    Compiling Linker error

    I was compiling TheForgottenServer, when in the end, some errors appeared: obj//databasemysql.o(.text+0xfc):databasemysql.cpp: undefined reference to `mysql_init@4' obj//databasemysql.o(.text+0x17e):databasemysql.cpp: undefined reference to `mysql_options@12'...
  12. B

    Lua How to fix this script? Rep+

    Can someone help me? I was making a "advanced convince" for my server with tables, for example: local bribes = { ["Rat"] = { money = 5, item = "Cheese", chances = {1, 100000} }, ["Demon"] = { money = 100000, item = "Demon Shield", chances = {80000, 5000} } }...
  13. B

    Problems with SQL Query

    Hello, people. ^_^ I am with a problem... I need to return numbers with an SQL Query, like this: function getNumber(cid) return db.executeQuery("SELECT `number` FROM `players` WHERE id = ".. getPlayerGUID(cid) .."") end print(getNumber(cid)) The table 'number' have a number, for...
  14. B

    Lua A bug with item edition

    Hello, I have a problem with a system that I have made: function onKill(cid, target) if(getCreatureName(target) == "Rotworm") then if(getPlayerStorageValue(cid, 100002) == 1) then local item = doPlayerAddItem(cid, 11186) doItemSetAttribute(item, "name", "strange item")...
  15. B

    Lua Problem with NPC

    Hello, people! I have a problem with NPCs, in the area of TalkStates... Actually my NPCs isn't obbeying the talkstates, when I say 'yes', a NPC say all the his sentences related to the "yes", for example: if(msgcontains(msg, "yes")) then npcHandler:say("=)", cid) talkState[talkUser] = 2...
  16. B

    Again a help here

    Hello! I am wanting to use the old npc system BEFORE the 8.2x update. Is that okay, I changed a option in lib/npcsystem to use this system: NPCHANDLER_CONVBEHAVIOR = CONVERSATION_DEFAULT But now, the NPC is greeting the player with two messages!! 18:44 Wernardo: Welcome...
  17. B

    Beds...

    function onUse(cid, item, fromPosition, itemEx, toPosition) local xpos = {x = fromPosition.x+1, y = fromPosition.y, z = fromPosition.z, stackpos = 2} local x = getThingFromPos(xpos) local ypos = {x = fromPosition.x, y = fromPosition.y+1, z = fromPosition.z, stackpos = 2} local y =...
  18. B

    doItemSetAttribute

    I recently discovered that the LUA function doItemSetAttribute(uid) cannot do calculations right. If you write this, eg: doItemSetAttribute(itemEx.uid, "attack", getItemInfo(itemEx.itemid).attack*1.86) The result will be, probably, decimal. And the function will not work, in other words...
  19. B

    Need item to cast instant spell.

    This is possible? I'm making a spell for Paladins, that shoot a arrow and paralyze the target, and to use this spell, need 1 arrow. I can make the part that shoot the arrow and paralyze the target... But I am not able to do the part that need 1 arrow to cast the spell... Can anyone help me...
  20. B

    When a monster die, change a StorageValue

    Hello, I am developing a quest in my server... "When the player talk with the NPC, he request a favour. This favour is kill the wolf boss in Wolf's Cavern." What I want: When the wolf boss die, change the value of a Storage. For when the player kill him and talk with the NPC, he (the NPC)...
Back
Top