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

script help

gubbo123

New Member
Joined
Aug 15, 2017
Messages
151
Solutions
1
Reaction score
3
Duplicate Content
Tfs.1.2

LUA:
function onUse(player, item, fromPosition, target, toPosition, isHotkey)
    local newId = item:getId() + 1
    if newId > 5098 then
       newId = 5133
    end
    item:transform(newId)
    return true
end

im trying use this script, when i use the item, will tranform to next item id until the last item id 5133, after back to 5098 again, but the problem item when i use the item, go directly to last item id 5133 ;/
 
You posted same thread before and 2 of the Support Team gave you answers which you can use, Instead of posting in same old thread or mark your old thread you created new one?
Please read Support board rules to avoid getting banned.
You are breaking rule number 3#
3. Duplicate Content:
- Use only one thread to post about your problem. Creating more threads or posts about the same problem is seen as spam. If you don't get a reply on your thread, wait 24 hours to post again to show you still need help.
Anyways this should work try it.
LUA:
function onUse(player, item, fromPosition, target, toPosition, isHotkey)
    local newId = item:getId() - 1
    if newId > 5098 then
       newId = 5133
    end
    item:transform(newId)
    return true
end
 
Back
Top