• 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!
  • 2026 staff recruitment is open! Check it out and consider applying!

Search results

  1. N

    Lua Custom Skill Leveling

    Hey folks, I'm having an issue with custom skills. So when the player, uses the item for the skill it should level the players skill. But it doesn't seem to be working that way at all. Here is what I have so far. TFS 1.3 function Player.isGatheringJob(self, storage) if...
  2. N

    Lua Delete item after a certain time

    Yeah that makes sense. I decided to set the item to transform on a random basis. I then set the item attribute to decay back to the original form after 5 min. Main Function: function onUse(player, item, fromPosition, itemEx, toPosition) if item.itemid == 26405 and isInArray({50605, 50602...
  3. N

    Lua Delete item after a certain time

    So hey guys, back again. I would like to have my script start counting down when you use the item, then after 5 min, remove the item. I thought I had the syntax correct, but I can't seem to get it. It either deletes it right away or deletes it on the second click. Here is what I have so far...
  4. N

    Lua Remove corpse after using

    Xikini to the rescue as always! Thanks man!
  5. N

    Lua Remove corpse after using

    Hey folks, im trying to set it so that, when you use the corpse (2992 - dead rabbit) it removes the corpse for the game. I think i have the syntax wrong. I've tried, item:removeItem(2992, 1) as well as doRemoveItem(2992, 1) but have no success on either front. Here is what i have so far...
  6. N

    Lua Cannot use this item, but still runs code?

    Ah okay, thank you! That was a pretty good explanation lol, don't sell yourself too short.
  7. N

    Lua Cannot use this item, but still runs code?

    Just so I can learn, whats the difference in running return player:~~~ as apposed to running return true after the argument?
  8. N

    Lua Cannot use this item, but still runs code?

    So i adjusted all that but I'm still getting the you cannot use this, with the exception of the elseif on ln 125 function onUse(player, item, fromPosition, itemEx, toPosition) if item.itemid == 26405 and isInArray({50605, 50602, 50603, 50604}, item.actionid) then if...
  9. N

    Lua Cannot use this item, but still runs code?

    The thing is, it's not erroring out. Everything works great, except that it tells me i can;t use it even though im using it lol. 1598490804 It's doing the same thing with the books that teach the skills.
  10. N

    Lua Check to see if a player has said item in inventory

    All good lol. I shouldve caught that myself. Thanks guys works great minus the >you cannot use this item crap.... Lol
  11. N

    Lua Check to see if a player has said item in inventory

    That part of the script is working now that i changed the player:getItemById to player:getItemCount. It's just not registering if the item is in the backpack/bag. 1598490400 I commented out the check for the item and the code runs perfect.
  12. N

    Lua Check to see if a player has said item in inventory

    function onUse(player, item, fromPosition, itemEx, toPosition) if item.itemid == 26405 and isInArray({50605, 50602, 50603, 50604}, item.actionid) then if player:getCondition(player, CONDITION_COOLDOWN, 160) then return player:sendCancelMessage("You are already...
  13. N

    Lua Cannot use this item, but still runs code?

    function onUse(player, item, fromPosition, itemEx, toPosition) if item.itemid == 26405 and isInArray({50605, 50602, 50603, 50604}, item.actionid) then if player:getCondition(player, CONDITION_COOLDOWN, 160) then return player:sendCancelMessage("You are already...
  14. N

    Lua Check to see if a player has said item in inventory

    Im getting this error now 1598489490 Nvm, i changed it to ItemCount, but it tells me i need the pick, even if i have the pick in my bag
  15. N

    Lua Cannot use this item, but still runs code?

    Hey folks, I'm having a slight issue with my coding. I go to use the item in question, and the script runs no problem, but for some reason the cancel message "You cannot use this item" appears on the screen as I click the item to use. Any thoughts?
  16. N

    Lua Check to see if a player has said item in inventory

    Hey folks, I'm trying to get my scrip to check if the player has a certain item before doing an action, but it doesn't seem to want to work. I'm using TFS 1.3. Here is what I have so far. if player:getItemById(2553) then -- check for pick mathCheck = math.floor(math.random() * 100)...
  17. N

    CreatureEvent [TFS 1.3 / 1.4] Upgrade System

    Hey man, I'm getting this error when I try to use the upgrade crystal. 1598213360 Got it fixed up and working! Thanks man amazing addon!
  18. N

    C++ Adding text to buyable books.

    your way isnt kickingou the action id, so i had to change the lines up to to do that. Back to I cant use the object. -- Adds a new buyable item. -- names = A table containing one or more strings of alternative names to this item. Used only for old buy/sell system. -- itemid = The...
  19. N

    C++ Adding text to buyable books.

    That worked but, when i buy the scroll, it has no text in it, comes in blank.
  20. N

    C++ Adding text to buyable books.

    In game it's telling me I cannot use the item. -- Including the Advanced NPC System dofile('data/npc/lib/npcsystem/npcsystem.lua') function msgcontains(message, keyword) local message, keyword = message:lower(), keyword:lower() if message == keyword then return true end...
Back
Top