wow-addons/WA-MasterLootHelper/MasterLootHelper.table
Casper V. Kristensen 88a470d81a
Add WAs:
- AQ40 Anubisath Helper.
  - Fury Warrior.
  - Master Loot Helper
  - Raid Healer Mana.
  - AQ40 Skeram Helper.
  - World Buffs on Nameplates.
2020-09-22 19:56:50 +02:00

125 lines
5.2 KiB
Plaintext
Executable file

{
"d": {
"yOffset": 0,
"outline": "OUTLINE",
"conditions": [],
"color": [
1,
1,
1,
1
],
"load": {
"use_never": false,
"size": {
"multi": {
"flexible": true,
"twenty": true,
"fortyman": true,
"twentyfive": true,
"ten": true
}
},
"class": {
"multi": []
},
"ingroup": {
"single": "raid",
"multi": {
"raid": true
}
},
"zone": "",
"spec": {
"multi": []
},
"use_ingroup": true,
"use_size": false,
"use_zone": false
},
"fixedWidth": 200,
"shadowYOffset": -1,
"regionType": "text",
"animation": {
"main": {
"type": "none",
"duration_type": "seconds",
"easeType": "none",
"easeStrength": 3
},
"start": {
"type": "none",
"duration_type": "seconds",
"easeType": "none",
"easeStrength": 3
},
"finish": {
"type": "none",
"duration_type": "seconds",
"easeType": "none",
"easeStrength": 3
}
},
"subRegions": [],
"uid": "1UCRMNroKKs",
"anchorPoint": "CENTER",
"justify": "LEFT",
"shadowColor": [
0,
0,
0,
1
],
"selfPoint": "CENTER",
"font": "Friz Quadrata TT",
"wordWrap": "WordWrap",
"frameStrata": 1,
"displayText": "",
"anchorFrameType": "SCREEN",
"xOffset": 0,
"config": [],
"id": "MasterLootHelper",
"internalVersion": 33,
"authorOptions": [],
"automaticWidth": "Auto",
"fontSize": 12,
"triggers": {
"1": {
"untrigger": [],
"trigger": {
"unit": "player",
"debuffType": "HELPFUL",
"custom_hide": "timed",
"subeventSuffix": "_CAST_START",
"custom": "function(event)\n lootMethod, masterLooterPartyID, masterLooterRaidID = GetLootMethod()\n if lootMethod ~= \"master\" then\n return false\n end\n if not UnitIsUnit(\"raid\"..masterLooterRaidID, \"player\") then\n return false\n end\n \n for slot = 1, GetNumLootItems() do\n if GetLootSlotType(slot) ~= LOOT_SLOT_ITEM then\n LootSlot(slot)\n else\n local itemID = tonumber(GetLootSlotLink(slot):match(\"item:(%d+):\"))\n local lootStrategy = aura_env.lootStrategies[itemID]\n if lootStrategy == nil or not lootStrategy(slot) then -- lootStrategy returns true if item looted by it\n -- default loot to own bag\n for candidate = 1, GetNumGroupMembers() do\n if GetMasterLootCandidate(slot, candidate) == UnitName(\"player\") then\n GiveMasterLoot(slot, candidate)\n break\n end\n end \n end \n end \n end\n return true\nend",
"names": [],
"events": "LOOT_READY",
"event": "Health",
"type": "custom",
"custom_type": "event",
"subeventPrefix": "SPELL",
"spellIds": []
}
},
"activeTriggerMode": -10
},
"customTextUpdate": "event",
"shadowXOffset": 1,
"actions": {
"init": {
"custom": "if not _G.WA_MasterLootHelper then\n _G.WA_MasterLootHelper = {\n [\"sands\"] = {},\n [\"coins\"] = {},\n [\"bijous\"] = {},\n }\nend\n\n\nfunction roundRobin(lookupKey)\n local wanted = 1\n local function loot(slot)\n local _, _, itemQuantity = GetLootSlotInfo(slot)\n local r = math.random(GetNumGroupMembers())\n for c0 = 1, GetNumGroupMembers() do\n local c = ((c0 + r) % GetNumGroupMembers()) + 1\n local candidate = GetMasterLootCandidate(slot, c)\n if candidate ~= nil then\n local candidateReceived = _G.WA_MasterLootHelper[lookupKey][candidate]\n if candidateReceived == nil or candidateReceived < wanted then\n GiveMasterLoot(slot, c)\n _G.WA_MasterLootHelper[lookupKey][candidate] = itemQuantity\n return true\n end\n end\n end\n wanted = wanted + 1\n return loot(slot)\n end\n return loot\nend\n\n\nlocal lootStrategies = {\n { -- BWL Hourglass Sand\n [\"ids\"] = {19183},\n [\"func\"] = roundRobin(\"sands\")\n },\n { -- Zul'Gurub Coins\n [\"ids\"] = {19698, 19699, 19700, 19701, 19702, 19703, 19704, 19705, 19706},\n [\"func\"] = roundRobin(\"coins\")\n },\n { -- Zul'Gurub Bijous\n [\"ids\"] = {19707, 19708, 19709, 19710, 19711, 19712, 19713, 19714, 19715},\n [\"func\"] = roundRobin(\"bijous\")\n }\n \n}\naura_env.lootStrategies = {}\nfor _, strategy in ipairs(lootStrategies) do\n for _, id in ipairs(strategy.ids) do\n aura_env.lootStrategies[id] = strategy.func\n end\nend\n\n\n",
"do_custom": true
},
"start": [],
"finish": []
},
"tocversion": 11305,
"url": "https://wago.io/sTT8_GdLS/1",
"version": 1,
"semver": "1.0.0"
},
"m": "d",
"s": "2.18.2",
"v": 1421,
"wagoID": "sTT8_GdLS"
}