origamidoizin
Member
- Joined
- Jan 2, 2024
- Messages
- 19
- Reaction score
- 6
hi guys i have a code that add storage to players but i have a event in my server everyday and need add and remove storage to more than 50 players every day and its makin me crazy, there is a way that i can add a storage to all guild members? im nub and tried many ways like using war talkaction code, implementing other codes i saw but nothing works, if smn good heart can help? i guess it is easy to do but need some tips to do that, ty anyway
MY CODE:
MY CODE:
Lua:
function onSay(player, words, param)
if not player:getGroup():getAccess() then
return true
end
if player:getAccountType() < ACCOUNT_TYPE_GOD then
return false
end
local split = param:split(",")
if split[2] == nil or split[3] == nil then
player:sendCancelMessage("Insufficient parameters.")
return false
end
local target = Player(split[1])
if target == nil then
player:sendCancelMessage("Player with name does not exist or is not online.")
return false
end
if split[4] ~= nil then
player:sendCancelMessage("Too many parameters.")
return false
end
target:setStorageValue(split[2], split[3])
return false
end