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

[TFS 1.3] Advanced quest chests

beenii

Well-Known Member
Joined
Jul 26, 2010
Messages
580
Solutions
1
Reaction score
57
System by strutZ with a small modification to do anahi type quest
4 chest 1 reward.

Features
  • Easy config
  • Can add level requirements for chests
  • Supports Item Rewards
  • Supports Experience Rewards
  • Supports Outfit Rewards
  • Supports Addon Rewards
  • Supports Mount Rewards
  • Supports Anihi Quest (4 Chest only select 1 Chest)

This system currently supports up to 100 chests. o add more simply up the change 2000, 2100 in data/scripts/actions/quest_chests.lua

add
in data/lib/lib.lua
Lua:
dofile('data/lib/quest_chests.lua')


data/lib/quest_chests.lua
Lua:
questChests = {
    ---------------------------------------------------------
   -- Example Quest Box 1
   ---------------------------------------------------------
   [2000] = {
       minLevel = 50,
       storageUnique = 2000,
       items = {
           [1] = {type = "item", item = 2160, count = 1},
           [2] = {type = "experience", amount = 20000},
           [3] = {type = "outfit", name = "assassin", femaleId = 156, maleId = 152},
           [4] = {type = "addon", outfit = "nobleman", addonNumber = 1, femaleId = 140, maleId = 132},
           [5] = {type = "mount", mountName = "Orc", mountId = 20},
       },
   },
 
     ---------------------------------------------------------
   -- Example Quest Box 2 like anihi 2 reward only select 1
   ---------------------------------------------------------
   [2001] = {
       minLevel = 50,
       storageUnique = 2001, -- put same storage for only select 1 reward
       items = {
           [1] = {type = "item", item = 2160, count = 1},
           [2] = {type = "experience", amount = 20000},
           [3] = {type = "outfit", name = "assassin", femaleId = 156, maleId = 152},
           [4] = {type = "addon", outfit = "nobleman", addonNumber = 1, femaleId = 140, maleId = 132},
           [5] = {type = "mount", mountName = "Orc", mountId = 20},
       },
   },
    [2002] = {
       minLevel = 50,
       storageUnique = 2001, -- put same storage for only select 1 reward
       items = {
           [1] = {type = "item", item = 2160, count = 1},
           [2] = {type = "experience", amount = 20000},
           [3] = {type = "outfit", name = "assassin", femaleId = 156, maleId = 152},
           [4] = {type = "addon", outfit = "nobleman", addonNumber = 1, femaleId = 140, maleId = 132},
           [5] = {type = "mount", mountName = "Orc", mountId = 20},
       },
   }
 
 
}


data/scripts/actions/quest_chests.lua
Lua:
function capAll(str)
    return (str:gsub("(%l)(%w*)", function(a,b) return string.upper(a)..b end))
end

local advanceChest = Action()

function advanceChest.onUse(player, item, fromPosition, itemEx, toPosition)
   -----------------------------------------------------------------------------------
   -- Local Variables --
   -----------------------------------------------------------------------------------
   local questChest = item:getUniqueId()
   -----------------------------------------------------------------------------------
   -- Check if player has already opened box --
   -----------------------------------------------------------------------------------
   if player:getStorageValue(questChest) == 1 then
       player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "The chest is empty.")
       toPosition:sendMagicEffect(10)
       return true
   end
 
   local storageOne = questChests[questChest].storageUnique
   -----------------------------------------------------------------------------------
   -- Check if player has already opened box multiple chest only 1 reward --
   -----------------------------------------------------------------------------------
   if player:getStorageValue(storageOne) == 1 then
       player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "The chest is empty.")
       toPosition:sendMagicEffect(10)
       return true
   end 
 
   -----------------------------------------------------------------------------------
   -- Check if player meets level requirment
   -----------------------------------------------------------------------------------
   local playerLevel = player:getLevel()
   local minLevel = questChests[questChest].minLevel
   if questChests[questChest].minLevel => playerLevel then
       player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "You need to be level "..minLevel.." to open this chest.")
       return true
   end
   -----------------------------------------------------------------------------------
 
   -- Give rewward if player has not yet opened box --
 
   -----------------------------------------------------------------------------------
   for i = 1, #questChests[questChest].items do
       local rewardType = questChests[questChest].items[i].type
       -----------------------------------------------------------------------------------
       -- Item Type Reward --
       -----------------------------------------------------------------------------------
       if rewardType == "item" then
           local item = questChests[questChest].items[i].item
           local count = questChests[questChest].items[i].count
           player:addItem(item, count)
           player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You earned ["..count.."x] "..capAll(getItemName(item)))
       end
       -----------------------------------------------------------------------------------
       -- Experience Type Reward --
       -----------------------------------------------------------------------------------
       if rewardType == "experience" then
           local amount = questChests[questChest].items[i].amount
           player:addExperience(amount)
           player:say(amount.." EXP gained!", TALKTYPE_MONSTER_SAY)
           player:getPosition():sendMagicEffect(CONST_ME_STUN)
           player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You gained "..amount.." experience points.")
       end
       -----------------------------------------------------------------------------------
       -- Outfit Type Reward --
       -----------------------------------------------------------------------------------
       if rewardType == "outfit" then
           local outfitName = questChests[questChest].items[i].name
           local maleOutfit = questChests[questChest].items[i].maleId
           local femaleOutfit = questChests[questChest].items[i].femaleId
           if player:getSex() == 0 then
               player:addOutfit(femaleOutfit)
           else
               player:addOutfit(maleOutfit)
           end
           player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You gained the "..outfitName.." outfit.")
       end
       -----------------------------------------------------------------------------------
       -- Addon Type Reward --
       -----------------------------------------------------------------------------------
       if rewardType == "addon" then
           local outfitName = questChests[questChest].items[i].outfit
           local addon = questChests[questChest].items[i].addonNumber
           local maleAddon = questChests[questChest].items[i].maleId
           local femaleAddon = questChests[questChest].items[i].femaleId
           if player:getSex() == 0 then
               player:addOutfitAddon(femaleAddon, addon)
           else
               player:addOutfitAddon(maleAddon, addon)
           end
           if addon == 1 then
               player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You gained the first "..outfitName.." outfit addon.")
           elseif addon == 2 then
               player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You gained the second "..outfitName.." outfit addon.")
           elseif addon == 3 then
               player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You gained the third "..outfitName.." outfit addon.")
           end
       end
       -----------------------------------------------------------------------------------
       -- Mount Type Reward --
       -----------------------------------------------------------------------------------
       if rewardType == "mount" then
           local mountName = questChests[questChest].items[i].mountName
           local mountId = questChests[questChest].items[i].mountId
           player:addMount(mountId)
           player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You have unlocked the "..mountName.." mount.")
       end

            
 
 
   -----------------------------------------------------------------------------------
   -- Add in any cooldowns/storages --
   -----------------------------------------------------------------------------------
   player:setStorageValue(questChest, 1)
   player:setStorageValue(storageOne, 1)
   return true
end
end

for i = 2000, 2100 do
    advanceChest:uid(i)
end

advanceChest:register()


It is a very useful system, since it has a simple organization, I hope my contribution will serve you.
 
Last edited:
Lua Script Error: [Test Interface]
data/actions/scripts/questchests.lua
data/actions/scripts/questchests.lua:5: attempt to call global 'Action' (a nil value)
stack traceback:
[C]: in function 'Action'
data/actions/scripts/questchests.lua:5: in main chunk
[Warning - Event::checkScript] Can not load script: scripts/questchests.lua
 
Modification in data/lib/lib.lua is not neccesary, you can just change the path of data/lib/quest_chests.lua file to data/scripts/lib/quest_chests.lua, Revscriptsys will load files in data/scripts/lib/ as lib files automatically.
 
Modification in data/lib/lib.lua is not neccesary, you can just change the path of data/lib/quest_chests.lua file to data/scripts/lib/quest_chests.lua, Revscriptsys will load files in data/scripts/lib/ as lib files automatically.
thanks for letting me know, i will modify
 
I want make it for multiple reward from chest, what I need to edit to do it? Example I want from one chest itemid - 2160 and 10k exp.

I'm using tfs 1.4 for 8.6 version
 
I want make it for multiple reward from chest, what I need to edit to do it? Example I want from one chest itemid - 2160 and 10k exp.

I'm using tfs 1.4 for 8.6 version
Lua:
[2000] = {
    minLevel = 50,
    storageUnique = 2000,
    items = {
        [1] = {type = "item", item = 2160, count = 1},
        [2] = {type = "experience", amount = 10000},
    },
},
 
Lua:
[2000] = {
    minLevel = 50,
    storageUnique = 2000,
    items = {
        [1] = {type = "item", item = 2160, count = 1},
        [2] = {type = "experience", amount = 10000},
    },
},
Hello bro, I hope you are well, you know I am looking for a tfs 1.4 script to be able to create normal quests, and not use the ones that come in the quests folder, also a script so that when you right-click it, it creates a creature, but that has to require level to be able to use it. It would be of great help thanks <3 you are the best
 
Hello bro, I hope you are well, you know I am looking for a tfs 1.4 script to be able to create normal quests, and not use the ones that come in the quests folder
The thread you're in is for creating normal quest chests/items?
If this isn't what you want, you'll have to explain better.
also a script so that when you right-click it, it creates a creature, but that has to require level to be able to use it.
You should create your own thread for this.
The main reason is so people in the future will be able to find it more easily, and I might not have the time/experience/inclination to create every request someone makes, so making your own thread will allow other people to help you.

On that front, go make a thread here, and I'll post the script there for you.
It would be of great help thanks <3 you are the best
Appreciate it.
 
The thread you're in is for creating normal quest chests/items?
If this isn't what you want, you'll have to explain better.

You should create your own thread for this.
The main reason is so people in the future will be able to find it more easily, and I might not have the time/experience/inclination to create every request someone makes, so making your own thread will allow other people to help you.

On that front, go make a thread here, and I'll post the script there for you.

Appreciate it.
Of course I mean a normal chest, that is, you go and press the chest and it gives you some objects, more than anything it is that. so I can create missions on the map. It would be a great help and right now I will create the thread and tag you if it is not a hassle.
 
Lua:
[2000] = {
    minLevel = 50,
    storageUnique = 2000,
    items = {
        [1] = {type = "item", item = 2160, count = 1},
        [2] = {type = "experience", amount = 10000},
    },
},
Ye, I try it before I post here, but its don't work for me, I get only one crystal coin and nothing more. It can be problem with quest system? I'm using orginal from tfs 1.4 downgraded to 8.6 version in TFS-1.4-Downgrades-8.60\data\actions\scripts\quests:

Lua:
local annihilatorReward = {2421, 2400, 2431, 2494}
function onUse(player, item, fromPosition, target, toPosition, isHotkey)
    if item.uid <= 1250 or item.uid >= 30000 then
        return false
    end

    local itemType = ItemType(item.uid)
    if itemType:getId() == 0 then
        return false
    end

    local itemWeight = itemType:getWeight()
    local playerCap = player:getFreeCapacity()
    if table.contains(annihilatorReward, item.uid) then
        if player:getStorageValue(PlayerStorageKeys.annihilatorReward) == -1 then
            if playerCap >= itemWeight then
                if item.uid == 1990 then
                    player:addItem(1990, 1):addItem(2326, 1)
                else
                    player:addItem(item.uid, 1)
                end
                player:sendTextMessage(MESSAGE_EVENT_ADVANCE, 'You have found a ' .. itemType:getName() .. '.')
                player:setStorageValue(PlayerStorageKeys.annihilatorReward, 1)
                player:addAchievement("Annihilator")
            else
                player:sendTextMessage(MESSAGE_EVENT_ADVANCE, 'You have found a ' .. itemType:getName() .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
            end
        else
            player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "It is empty.")
        end
    elseif player:getStorageValue(item.uid) == -1 then
        if playerCap >= itemWeight then
            player:sendTextMessage(MESSAGE_EVENT_ADVANCE, 'You have found a ' .. itemType:getName() .. '.')
            player:addItem(item.uid, 1)
            player:setStorageValue(item.uid, 1)
        else
            player:sendTextMessage(MESSAGE_EVENT_ADVANCE, 'You have found a ' .. itemType:getName() .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
        end
    else
        player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "It is empty.")
    end
    return true
end
 
Ye, I try it before I post here, but its don't work for me, I get only one crystal coin and nothing more. It can be problem with quest system? I'm using orginal from tfs 1.4 downgraded to 8.6 version in TFS-1.4-Downgrades-8.60\data\actions\scripts\quests:

Lua:
local annihilatorReward = {2421, 2400, 2431, 2494}
function onUse(player, item, fromPosition, target, toPosition, isHotkey)
    if item.uid <= 1250 or item.uid >= 30000 then
        return false
    end

    local itemType = ItemType(item.uid)
    if itemType:getId() == 0 then
        return false
    end

    local itemWeight = itemType:getWeight()
    local playerCap = player:getFreeCapacity()
    if table.contains(annihilatorReward, item.uid) then
        if player:getStorageValue(PlayerStorageKeys.annihilatorReward) == -1 then
            if playerCap >= itemWeight then
                if item.uid == 1990 then
                    player:addItem(1990, 1):addItem(2326, 1)
                else
                    player:addItem(item.uid, 1)
                end
                player:sendTextMessage(MESSAGE_EVENT_ADVANCE, 'You have found a ' .. itemType:getName() .. '.')
                player:setStorageValue(PlayerStorageKeys.annihilatorReward, 1)
                player:addAchievement("Annihilator")
            else
                player:sendTextMessage(MESSAGE_EVENT_ADVANCE, 'You have found a ' .. itemType:getName() .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
            end
        else
            player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "It is empty.")
        end
    elseif player:getStorageValue(item.uid) == -1 then
        if playerCap >= itemWeight then
            player:sendTextMessage(MESSAGE_EVENT_ADVANCE, 'You have found a ' .. itemType:getName() .. '.')
            player:addItem(item.uid, 1)
            player:setStorageValue(item.uid, 1)
        else
            player:sendTextMessage(MESSAGE_EVENT_ADVANCE, 'You have found a ' .. itemType:getName() .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
        end
    else
        player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "It is empty.")
    end
    return true
end
The script you posted has nothing to do with this thread.
The script in this thread is a stand-alone system. It's not meant to be incorporated into other scripts.

The basic idea is that you put a UniqueId on a chest in your map editor

Then create a new table entry in data/lib/quest_chests.lua, that tells the server what reward you get from that chest.

Just step 1, step 2. Done.

---
If you need help with the script you posted, open up a new thread in Support.
 
if questChests[questChest].minLevel => playerLevel then
On line 36 is a minor error. change => to <
return true
end
end
Lines 119-121 are slightly scuffed.
With the return true being inside of the loop, only 1 reward will be given, instead of all in the table.

change for
Lua:
    end
    return true
end

That should solve your issue @Crest
 
Hello, getting this error.

Lua Script Error: [Scripts Interface]
C:\Users\Administrator\Desktop\Server\data\scripts\actions\quest_chests.lua:callback
...tor\Desktop\Server\data\scripts\actions\quest_chests.lua:21: attempt to index a nil value

Any idea why it is?. TFS 1.4.

Thanks
 
Very good working well.
My only problem I'm having is in the delivery of Addons, it's not giving the addons to the character

[20124] = { -- Robe of the underworld
minLevel = 80,
storageUnique = 20116,
items = {
[1] = {type = "item", item = 8890, count = 1},
[2] = {type = "addon", outfit = "Demon Hunter", addonNumber = 1, femaleId = 288, maleId = 289},
[3] = {type = "addon", outfit = "Demon Hunter", addonNumber = 2, femaleId = 288, maleId = 289},
[4] = {type = "addon", outfit = "Demon Hunter", addonNumber = 3, femaleId = 288, maleId = 289}
},
}
 
System by strutZ with a small modification to do anahi type quest
4 chest 1 reward.

Features
  • Easy config
  • Can add level requirements for chests
  • Supports Item Rewards
  • Supports Experience Rewards
  • Supports Outfit Rewards
  • Supports Addon Rewards
  • Supports Mount Rewards
  • Supports Anihi Quest (4 Chest only select 1 Chest)

This system currently supports up to 100 chests. o add more simply up the change 2000, 2100 in data/scripts/actions/quest_chests.lua

add
in data/lib/lib.lua
Lua:
dofile('data/lib/quest_chests.lua')


data/lib/quest_chests.lua
Lua:
questChests = {
    ---------------------------------------------------------
   -- Example Quest Box 1
   ---------------------------------------------------------
   [2000] = {
       minLevel = 50,
       storageUnique = 2000,
       items = {
           [1] = {type = "item", item = 2160, count = 1},
           [2] = {type = "experience", amount = 20000},
           [3] = {type = "outfit", name = "assassin", femaleId = 156, maleId = 152},
           [4] = {type = "addon", outfit = "nobleman", addonNumber = 1, femaleId = 140, maleId = 132},
           [5] = {type = "mount", mountName = "Orc", mountId = 20},
       },
   },
 
     ---------------------------------------------------------
   -- Example Quest Box 2 like anihi 2 reward only select 1
   ---------------------------------------------------------
   [2001] = {
       minLevel = 50,
       storageUnique = 2001, -- put same storage for only select 1 reward
       items = {
           [1] = {type = "item", item = 2160, count = 1},
           [2] = {type = "experience", amount = 20000},
           [3] = {type = "outfit", name = "assassin", femaleId = 156, maleId = 152},
           [4] = {type = "addon", outfit = "nobleman", addonNumber = 1, femaleId = 140, maleId = 132},
           [5] = {type = "mount", mountName = "Orc", mountId = 20},
       },
   },
    [2002] = {
       minLevel = 50,
       storageUnique = 2001, -- put same storage for only select 1 reward
       items = {
           [1] = {type = "item", item = 2160, count = 1},
           [2] = {type = "experience", amount = 20000},
           [3] = {type = "outfit", name = "assassin", femaleId = 156, maleId = 152},
           [4] = {type = "addon", outfit = "nobleman", addonNumber = 1, femaleId = 140, maleId = 132},
           [5] = {type = "mount", mountName = "Orc", mountId = 20},
       },
   }
 
 
}


data/scripts/actions/quest_chests.lua
Lua:
function capAll(str)
    return (str:gsub("(%l)(%w*)", function(a,b) return string.upper(a)..b end))
end

local advanceChest = Action()

function advanceChest.onUse(player, item, fromPosition, itemEx, toPosition)
   -----------------------------------------------------------------------------------
   -- Local Variables --
   -----------------------------------------------------------------------------------
   local questChest = item:getUniqueId()
   -----------------------------------------------------------------------------------
   -- Check if player has already opened box --
   -----------------------------------------------------------------------------------
   if player:getStorageValue(questChest) == 1 then
       player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "The chest is empty.")
       toPosition:sendMagicEffect(10)
       return true
   end
 
   local storageOne = questChests[questChest].storageUnique
   -----------------------------------------------------------------------------------
   -- Check if player has already opened box multiple chest only 1 reward --
   -----------------------------------------------------------------------------------
   if player:getStorageValue(storageOne) == 1 then
       player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "The chest is empty.")
       toPosition:sendMagicEffect(10)
       return true
   end
 
   -----------------------------------------------------------------------------------
   -- Check if player meets level requirment
   -----------------------------------------------------------------------------------
   local playerLevel = player:getLevel()
   local minLevel = questChests[questChest].minLevel
   if questChests[questChest].minLevel => playerLevel then
       player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "You need to be level "..minLevel.." to open this chest.")
       return true
   end
   -----------------------------------------------------------------------------------
 
   -- Give rewward if player has not yet opened box --
 
   -----------------------------------------------------------------------------------
   for i = 1, #questChests[questChest].items do
       local rewardType = questChests[questChest].items[i].type
       -----------------------------------------------------------------------------------
       -- Item Type Reward --
       -----------------------------------------------------------------------------------
       if rewardType == "item" then
           local item = questChests[questChest].items[i].item
           local count = questChests[questChest].items[i].count
           player:addItem(item, count)
           player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You earned ["..count.."x] "..capAll(getItemName(item)))
       end
       -----------------------------------------------------------------------------------
       -- Experience Type Reward --
       -----------------------------------------------------------------------------------
       if rewardType == "experience" then
           local amount = questChests[questChest].items[i].amount
           player:addExperience(amount)
           player:say(amount.." EXP gained!", TALKTYPE_MONSTER_SAY)
           player:getPosition():sendMagicEffect(CONST_ME_STUN)
           player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You gained "..amount.." experience points.")
       end
       -----------------------------------------------------------------------------------
       -- Outfit Type Reward --
       -----------------------------------------------------------------------------------
       if rewardType == "outfit" then
           local outfitName = questChests[questChest].items[i].name
           local maleOutfit = questChests[questChest].items[i].maleId
           local femaleOutfit = questChests[questChest].items[i].femaleId
           if player:getSex() == 0 then
               player:addOutfit(femaleOutfit)
           else
               player:addOutfit(maleOutfit)
           end
           player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You gained the "..outfitName.." outfit.")
       end
       -----------------------------------------------------------------------------------
       -- Addon Type Reward --
       -----------------------------------------------------------------------------------
       if rewardType == "addon" then
           local outfitName = questChests[questChest].items[i].outfit
           local addon = questChests[questChest].items[i].addonNumber
           local maleAddon = questChests[questChest].items[i].maleId
           local femaleAddon = questChests[questChest].items[i].femaleId
           if player:getSex() == 0 then
               player:addOutfitAddon(femaleAddon, addon)
           else
               player:addOutfitAddon(maleAddon, addon)
           end
           if addon == 1 then
               player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You gained the first "..outfitName.." outfit addon.")
           elseif addon == 2 then
               player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You gained the second "..outfitName.." outfit addon.")
           elseif addon == 3 then
               player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You gained the third "..outfitName.." outfit addon.")
           end
       end
       -----------------------------------------------------------------------------------
       -- Mount Type Reward --
       -----------------------------------------------------------------------------------
       if rewardType == "mount" then
           local mountName = questChests[questChest].items[i].mountName
           local mountId = questChests[questChest].items[i].mountId
           player:addMount(mountId)
           player:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "You have unlocked the "..mountName.." mount.")
       end

          
 
 
   -----------------------------------------------------------------------------------
   -- Add in any cooldowns/storages --
   -----------------------------------------------------------------------------------
   player:setStorageValue(questChest, 1)
   player:setStorageValue(storageOne, 1)
   return true
end
end

for i = 2000, 2100 do
    advanceChest:uid(i)
end

advanceChest:register()


It is a very useful system, since it has a simple organization, I hope my contribution will serve you.
Lua:
questChests = {
    ---------------------------------------------------------
    -- Example Quest Box 1
    ---------------------------------------------------------
    [20007] = {
        storageUnique = 2108,
        minLevel = 1,
        items = {
            [1] = {type = "item", item = 2160, count = 1},
            [2] = {type = "item", item = 2434, count = 1}, -- Demon Helmet
            [3] = {type = "item", item = 2434, count = 1}, -- Demon Armor
            [4] = {type = "item", item = 2434, count = 1}, --Demon Legs
        },
    },
   
    [20000] = {
        storageUnique = 2000,
        minLevel = 1,
        items = {
            [1] = {type = "item", item = 2434, count = 1},
            [2] = {type = "experience", amount = 10000},
        },
    },
}

how do i add more than 1 item example
 
Lua:
questChests = {
    ---------------------------------------------------------
    -- Example Quest Box 1
    ---------------------------------------------------------
    [20007] = {
        storageUnique = 2108,
        minLevel = 1,
        items = {
            [1] = {type = "item", item = 2160, count = 1},
            [2] = {type = "item", item = 2434, count = 1}, -- Demon Helmet
            [3] = {type = "item", item = 2434, count = 1}, -- Demon Armor
            [4] = {type = "item", item = 2434, count = 1}, --Demon Legs
        },
    },
  
    [20000] = {
        storageUnique = 2000,
        minLevel = 1,
        items = {
            [1] = {type = "item", item = 2434, count = 1},
            [2] = {type = "experience", amount = 10000},
        },
    },
}

how do i add more than 1 item example
Code:
---------------------------------------------------------
-- Example Quest Box 1
---------------------------------------------------------
    [20007] = {
        storageUnique = 2108,
        minLevel = 1,
        items = {
            [1] = {type = "item", item = 2160, count = 1},
            [2] = {type = "item", item = 2434, count = 1}, -- Demon Helmet
            [3] = {type = "item", item = 2434, count = 1}, -- Demon Armor
            [4] = {type = "item", item = 2434, count = 1}, --Demon Legs
        },
    },
 
min level does not seems to work, i tried to open a lvl 50 chest, with a lvl 200 and it requires 50 exactly perhaps
 
Back
Top