adrenyslopez
Member
- Joined
- Dec 22, 2015
- Messages
- 201
- Reaction score
- 15
Hello, can someone help me with this script that I was doing but I want you to only be able to use these items if you have this storage
Storage: 69812
i used otbr tfs 1.3
Storage: 69812
i used otbr tfs 1.3
Lua:
local addcustom1 = Action()
function addcustom1.onUse(player, item, fromPosition, target, toPosition, isHotkey)
if player:getStorageValue(9240) == 1 then
doPlayerSendTextMessage(player, MESSAGE_EVENT_ADVANCE, "You have already used it.")
return true
end
Item(item.uid):remove(1)
player:removeItem(38911, 1)
player:addOutfitAddon(1323, 1)
player:addOutfitAddon(1322, 1)
player:setStorageValue(9240, 1)
player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "Obtained first addon Revenant.")
player:getPosition():sendMagicEffect(75)
return true
end
addcustom1:id(38911)
addcustom1:register()