wow-addons/WA-ConsumableCounter/ConsumableCounter.table
2020-11-21 11:55:51 +01:00

403 lines
11 KiB
Plaintext
Executable file

{
"c": [
{
"actions": {
"finish": [],
"init": {
"custom": "-- config\naura_env.consumables = {}\nfor _, consumable in ipairs({strsplit(\"\\n\", aura_env.config[\"consumables\"])}) do\n local name, wanted = strsplit(\":\", consumable)\n aura_env.consumables[name] = tonumber(wanted)\nend",
"do_custom": true
},
"start": []
},
"alpha": 1,
"anchorFrameType": "SCREEN",
"anchorPoint": "CENTER",
"animation": {
"finish": {
"duration_type": "seconds",
"easeStrength": 3,
"easeType": "none",
"type": "none"
},
"main": {
"duration_type": "seconds",
"easeStrength": 3,
"easeType": "none",
"type": "none"
},
"start": {
"duration_type": "seconds",
"easeStrength": 3,
"easeType": "none",
"type": "none"
}
},
"authorOptions": [
{
"default": "",
"key": "consumables",
"length": 10,
"multiline": true,
"name": "Consumables",
"type": "input",
"useDesc": false,
"useLength": false,
"width": 2
}
],
"auto": true,
"color": [
1,
1,
1,
1
],
"conditions": [
{
"changes": [
{
"property": "sub.1.text_color",
"value": [
1,
0,
0,
1
]
}
],
"check": {
"op": "==",
"trigger": 2,
"value": "0",
"variable": "stacks"
}
},
{
"changes": [
{
"property": "sub.2.text_color",
"value": [
0,
1,
0,
1
]
},
{
"property": "alpha",
"value": 0.5
}
],
"check": {
"trigger": 2,
"value": 1,
"variable": "satisfied"
}
}
],
"config": {
"consumables": "Elemental Sharpening Stone:6\nElixir of Greater Agility:5\nElixir of Giants:5\nElixir of the Mongoose:10\nJuju Power:20\nJuju Might:40\nR.O.I.D.S.:1\nMighty Rage Potion:20\nLimited Invulnerability Potion:15\nFree Action Potion:10\nSmoked Desert Dumplings:20\nHeavy Runecloth Bandage:20\nGoblin Sapper Charge:20\nColdrage Dagger:2\nCenarion Plant Salve:2\nHourglass Sand:5\nGnomish Mind Control Cap:1\nCache of Mau'ari:1\nNifty Stopwatch:1\nInvisibility Potion:5\nInsignia of the Alliance:1\nGreater Fire Protection Potion:5\nGreater Frost Protection Potion:5\nGreater Nature Protection Potion:10\nGreater Shadow Protection Potion:10\nGreater Arcane Protection Potion:5\nGnomish Cloaking Device:1\nGoblin Rocket Helmet:1\nParachute Cloak:1\nWhipper Root Tuber:20\nAnti-Venom:10\nStrong Anti-Venom:10\nPowerful Anti-Venom:10\nElixir of Poison Resistance:10"
},
"cooldown": false,
"cooldownEdge": false,
"cooldownSwipe": true,
"cooldownTextDisabled": false,
"desaturate": false,
"frameStrata": 1,
"height": 35,
"icon": true,
"id": "Consumables Counter Icon",
"ignoreOptionsEventErrors": true,
"internalVersion": 38,
"inverse": false,
"keepAspectRatio": false,
"load": {
"class": {
"multi": [],
"single": "WARRIOR"
},
"size": {
"multi": []
},
"spec": {
"multi": []
},
"use_class": true
},
"regionType": "icon",
"selfPoint": "CENTER",
"semver": "1.0.0",
"subRegions": [
{
"anchorXOffset": 0,
"anchorYOffset": 0,
"rotateText": "NONE",
"text_anchorPoint": "OUTER_TOP",
"text_automaticWidth": "Auto",
"text_color": [
1,
1,
1,
1
],
"text_fixedWidth": 64,
"text_font": "Friz Quadrata TT",
"text_fontSize": 14,
"text_fontType": "OUTLINE",
"text_justify": "CENTER",
"text_selfPoint": "AUTO",
"text_shadowColor": [
0,
0,
0,
1
],
"text_shadowXOffset": 0,
"text_shadowYOffset": 0,
"text_text": "%s",
"text_text_format_s_format": "none",
"text_visible": true,
"text_wordWrap": "WordWrap",
"type": "subtext"
},
{
"anchorXOffset": 0,
"anchorYOffset": 0,
"rotateText": "NONE",
"text_anchorPoint": "OUTER_BOTTOM",
"text_automaticWidth": "Auto",
"text_color": [
1,
0,
0,
1
],
"text_fixedWidth": 64,
"text_font": "Friz Quadrata TT",
"text_fontSize": 12,
"text_fontType": "OUTLINE",
"text_justify": "CENTER",
"text_selfPoint": "AUTO",
"text_shadowColor": [
0,
0,
0,
1
],
"text_shadowXOffset": 0,
"text_shadowYOffset": 0,
"text_text": "%p/%t",
"text_text_format_p_format": "timed",
"text_text_format_p_time_dynamic": false,
"text_text_format_p_time_precision": 0,
"text_text_format_t_format": "timed",
"text_text_format_t_time_dynamic": false,
"text_text_format_t_time_precision": 0,
"text_visible": true,
"text_wordWrap": "WordWrap",
"type": "subtext"
},
{
"anchorXOffset": 0,
"anchorYOffset": 0,
"rotateText": "LEFT",
"text_anchorPoint": "TOP",
"text_anchorXOffset": 0,
"text_anchorYOffset": 20,
"text_automaticWidth": "Auto",
"text_color": [
1,
1,
1,
1
],
"text_fixedWidth": 64,
"text_font": "Friz Quadrata TT",
"text_fontSize": 12,
"text_fontType": "OUTLINE",
"text_justify": "CENTER",
"text_selfPoint": "BOTTOM",
"text_shadowColor": [
0,
0,
0,
1
],
"text_shadowXOffset": 0,
"text_shadowYOffset": 0,
"text_text": "%n",
"text_text_format_n_format": "none",
"text_visible": true,
"text_wordWrap": "WordWrap",
"type": "subtext"
}
],
"tocversion": 11305,
"triggers": {
"1": {
"trigger": {
"check": "event",
"custom": "function(event)\n return event == \"BANKFRAME_OPENED\"\nend",
"custom_hide": "timed",
"custom_type": "status",
"debuffType": "HELPFUL",
"duration": "1",
"event": "Health",
"events": "BANKFRAME_OPENED BANKFRAME_CLOSED",
"names": [],
"spellIds": [],
"subeventPrefix": "SPELL",
"subeventSuffix": "_CAST_START",
"type": "custom",
"unevent": "auto",
"unit": "player",
"use_unit": true
},
"untrigger": []
},
"2": {
"trigger": {
"check": "event",
"custom": "function(allstates, event, containerID)\n for name, wanted in pairs(aura_env.consumables) do\n local bagCount = GetItemCount(name, false)\n local totalCount = GetItemCount(name, true)\n local bankCount = totalCount - bagCount\n allstates[name] = {\n show = true,\n changed = true,\n progressType = \"static\",\n name = name,\n index = name,\n icon = GetItemIcon(name),\n --itemId = 8410,\n stacks = bankCount,\n value = bagCount,\n total = wanted,\n satisfied = (bagCount >= wanted),\n }\n end\n return true\nend",
"customVariables": "{\n value = true,\n total = true,\n stacks = true,\n satisfied = \"bool\",\n}",
"custom_type": "stateupdate",
"debuffType": "HELPFUL",
"event": "Health",
"events": "BAG_UPDATE",
"names": [],
"spellIds": [],
"subeventPrefix": "SPELL",
"subeventSuffix": "_CAST_START",
"type": "custom",
"unit": "player"
},
"untrigger": []
},
"activeTriggerMode": 2
},
"uid": "uF4Je9FYTtZ",
"url": "https://wago.io/lsN0BQeyz/1",
"useTooltip": true,
"version": 1,
"width": 35,
"xOffset": 0,
"yOffset": 0,
"zoom": 0
}
],
"d": {
"actions": {
"finish": [],
"init": [],
"start": []
},
"align": "CENTER",
"anchorFrameType": "SCREEN",
"anchorPoint": "TOP",
"animate": false,
"animation": {
"finish": {
"duration_type": "seconds",
"easeStrength": 3,
"easeType": "none",
"type": "none"
},
"main": {
"duration_type": "seconds",
"easeStrength": 3,
"easeType": "none",
"type": "none"
},
"start": {
"duration_type": "seconds",
"easeStrength": 3,
"easeType": "none",
"type": "none"
}
},
"arcLength": 360,
"authorOptions": [],
"backdropColor": [
1,
1,
1,
0.5
],
"border": false,
"borderBackdrop": "Blizzard Tooltip",
"borderColor": [
0,
0,
0,
1
],
"borderEdge": "Square Full White",
"borderInset": 1,
"borderOffset": 4,
"borderSize": 2,
"columnSpace": 1,
"conditions": [],
"config": [],
"constantFactor": "RADIUS",
"frameStrata": 1,
"fullCircle": true,
"gridType": "RD",
"gridWidth": 5,
"groupIcon": 134827,
"grow": "RIGHT",
"id": "Consumables Counter",
"ignoreOptionsEventErrors": true,
"internalVersion": 38,
"limit": 5,
"load": {
"class": {
"multi": [],
"single": "WARRIOR"
},
"size": {
"multi": []
},
"spec": {
"multi": []
},
"use_class": "true"
},
"radius": 200,
"regionType": "dynamicgroup",
"rotation": 0,
"rowSpace": 1,
"scale": 1,
"selfPoint": "LEFT",
"semver": "1.0.0",
"sort": "none",
"space": 5,
"stagger": 0,
"subRegions": [],
"tocversion": 11305,
"triggers": [
{
"trigger": {
"debuffType": "HELPFUL",
"event": "Health",
"names": [],
"spellIds": [],
"subeventPrefix": "SPELL",
"subeventSuffix": "_CAST_START",
"type": "aura2",
"unit": "player"
},
"untrigger": []
}
],
"uid": "KZ4LeHmfUXU",
"url": "https://wago.io/lsN0BQeyz/1",
"useLimit": false,
"version": 1,
"xOffset": -943.00102996826,
"yOffset": -415.00048828125
},
"m": "d",
"s": "3.0.5",
"v": 1421,
"wagoID": "lsN0BQeyz"
}