Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ENT.lootList = {}
- ENT.lootList["Złom"] = {5, 100}
- ENT.lootList["Złom elektroniczny"] = {5,100}
- ENT.lootList["Żelazko"] = {5,75}
- ENT.lootList["Wiatrak biurowy"] = {5,25}
- ENT.lootList["Uszkodzona krótkofalówka"] = {5,25}
- ENT.lootList["Wiatrak biurowy"] = {5,25}
- local drops = self.lootList
- local loot = {}
- for v, k in pairs(drops) do
- local random = math.Rand(0, 100)
- if k[2] >= random then
- loot[v] = k
- end
- end
- while table.Count(loot) > 3 do
- for v, k in pairs(loot) do
- random = math.Rand(0, 100)
- if k[2] <= random then
- table.RemoveByValue( loot, v )
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement