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

doAddContainer function for tfs 0.3.4

Swimmi

♥Inactive♥
Joined
Jan 15, 2008
Messages
791
Reaction score
2
Location
Germany
Hello I need doAddContainer function for The Forgottenserver 0.3.4



Who Have it and can explain me how i add it??

i will add rep++ for sure for everyone who helped me

Thanks
 
Data/lib/function.lua

Code:
  function doPlayerBuyItemContainer(cid, containerid, itemid, count, cost, charges)
        if(doPlayerRemoveMoney(cid, cost) == TRUE) then
                for i = 1, count do
                        local container = doCreateItemEx(containerid, 1)
                        for x = 1, getContainerCapById(containerid) do
                                doAddContainerItem(container, itemid, charges)
                        end
                        doPlayerAddItemEx(cid, container)
                end
                return LUA_NO_ERROR
        end
        return LUA_ERROR
end


Help I Need too For TFS 0.2.2 Mystic Spirit!!!!
 
Data/lib/function.lua

Code:
  function doPlayerBuyItemContainer(cid, containerid, itemid, count, cost, charges)
        if(doPlayerRemoveMoney(cid, cost) == TRUE) then
                for i = 1, count do
                        local container = doCreateItemEx(containerid, 1)
                        for x = 1, getContainerCapById(containerid) do
                                doAddContainerItem(container, itemid, charges)
                        end
                        doPlayerAddItemEx(cid, container)
                end
                return LUA_NO_ERROR
        end
        return LUA_ERROR
end


Help I Need too For TFS 0.2.2 Mystic Spirit!!!!

thank, but i mean huw i can add this in item shop :D
 
Back
Top