Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions Locales/Locales.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
local addonName, PBM = ...

-- Taula global de localització per a l'addon
PBM.L = PBM.L or {}
local L = PBM.L

-- Metataula per retornar la clau original si no hi ha traducció
setmetatable(L, {
__index = function(t, key)
return key
end
})

-- Alias global per accedir-hi fàcilment des de qualsevol fitxer
PBM_L = L
2,178 changes: 2,178 additions & 0 deletions Locales/esES.lua

Large diffs are not rendered by default.

116 changes: 58 additions & 58 deletions PBM/IPTiersColor.lua
Original file line number Diff line number Diff line change
Expand Up @@ -46,70 +46,70 @@ PBM.TIER_KEY_COLORS = {

-- ── Full tier names (dropdowns, tooltips) ─────────────────────
PBM.TIER_LABELS = {
[0] = "T0 — Molten Core / Onyxia",
[1] = "T1 — Molten Core / Onyxia",
[2] = "T2 — Blackwing Lair",
[3] = "T3 — Ahn'Qiraj War Effort",
[4] = "T4 — AQ War",
[5] = "T5 — Ahn'Qiraj",
[6] = "T6 — Naxxramas 40",
[7] = "T7 — Pre-TBC",
[8] = "T8 — Karazhan / Gruul's Lair / Magtheridon's Lair",
[9] = "T9 — Serpentshrine Cavern / Tempest Keep",
[10] = "T10 — Hyjal Summit / Black Temple",
[11] = "T11 — Zul'Aman (Optional)",
[12] = "T12 — Sunwell Plateau",
[13] = "T13 — Naxx / Eye of Eternity / Obsidian Sanctum",
[14] = "T14 — Ulduar",
[15] = "T15 — Trial of the Crusader",
[16] = "T16 — Icecrown Citadel",
[17] = "T17 — Ruby Sanctum",
[18] = "T18 — Tiers Complete",
[0] = PBM_L["T0 — Molten Core / Onyxia"],
[1] = PBM_L["T1 — Molten Core / Onyxia"],
[2] = PBM_L["T2 — Blackwing Lair"],
[3] = PBM_L["T3 — Ahn'Qiraj War Effort"],
[4] = PBM_L["T4 — AQ War"],
[5] = PBM_L["T5 — Ahn'Qiraj"],
[6] = PBM_L["T6 — Naxxramas 40"],
[7] = PBM_L["T7 — Pre-TBC"],
[8] = PBM_L["T8 — Karazhan / Gruul's Lair / Magtheridon's Lair"],
[9] = PBM_L["T9 — Serpentshrine Cavern / Tempest Keep"],
[10] = PBM_L["T10 — Hyjal Summit / Black Temple"],
[11] = PBM_L["T11 — Zul'Aman (Optional)"],
[12] = PBM_L["T12 — Sunwell Plateau"],
[13] = PBM_L["T13 — Naxx / Eye of Eternity / Obsidian Sanctum"],
[14] = PBM_L["T14 — Ulduar"],
[15] = PBM_L["T15 — Trial of the Crusader"],
[16] = PBM_L["T16 — Icecrown Citadel"],
[17] = PBM_L["T17 — Ruby Sanctum"],
[18] = PBM_L["T18 — Tiers Complete"],
}

-- ── Short tier names (LevelSync grid, numLbl column) ─────────
-- T0 stays "None" because the server uses 0 to mean no tier achieved.
PBM.TIER_SHORT = {
[0] = "None",
[1] = "T1 - Molten Core",
[2] = "T2 - Blackwing Lair",
[3] = "T3 - Ahn'Qiraj War Effort",
[4] = "T4 - AQ War",
[5] = "T5 - Ahn'Qiraj",
[6] = "T6 - Naxxramas 40",
[7] = "T7 - Pre-TBC",
[8] = "T8 - Karazhan, Gruul's, Mag's",
[9] = "T9 - Serpentshrine / TK",
[10] = "T10 - Hyjal / Black Temple",
[11] = "T11 - Zul'Aman (Optional)",
[12] = "T12 - Sunwell Plateau",
[13] = "T13 - Naxx/EoE/OS",
[14] = "T14 - Ulduar",
[15] = "T15 - Trial of the Crusader",
[16] = "T16 - Icecrown Citadel",
[17] = "T17 - Ruby Sanctum",
[18] = "T18 - Complete",
[0] = PBM_L["None"],
[1] = PBM_L["T1 - Molten Core"],
[2] = PBM_L["T2 - Blackwing Lair"],
[3] = PBM_L["T3 - Ahn'Qiraj War Effort"],
[4] = PBM_L["T4 - AQ War"],
[5] = PBM_L["T5 - Ahn'Qiraj"],
[6] = PBM_L["T6 - Naxxramas 40"],
[7] = PBM_L["T7 - Pre-TBC"],
[8] = PBM_L["T8 - Karazhan, Gruul's, Mag's"],
[9] = PBM_L["T9 - Serpentshrine / TK"],
[10] = PBM_L["T10 - Hyjal / Black Temple"],
[11] = PBM_L["T11 - Zul'Aman (Optional)"],
[12] = PBM_L["T12 - Sunwell Plateau"],
[13] = PBM_L["T13 - Naxx/EoE/OS"],
[14] = PBM_L["T14 - Ulduar"],
[15] = PBM_L["T15 - Trial of the Crusader"],
[16] = PBM_L["T16 - Icecrown Citadel"],
[17] = PBM_L["T17 - Ruby Sanctum"],
[18] = PBM_L["T18 - Complete"],
}

-- ── Raid lists per tier (tooltip key hover) ───────────────────
PBM.TIER_TOOLTIP_RAIDS = {
[0] = {"Molten Core", "Onyxia's Lair"},
[1] = {"Molten Core", "Onyxia's Lair"},
[2] = {"Blackwing Lair"},
[3] = {"Ahn'Qiraj War Effort"},
[4] = {"AQ War"},
[5] = {"Ahn'Qiraj", "Ruins of Ahn'Qiraj"},
[6] = {"Naxxramas 40"},
[7] = {"Pre-TBC"},
[8] = {"Karazhan", "Gruul's Lair", "Magtheridon's Lair"},
[9] = {"Serpentshrine Cavern", "Tempest Keep"},
[10] = {"Mount Hyjal", "Black Temple"},
[11] = {"Zul'Aman (Optional)"},
[12] = {"Sunwell Plateau"},
[13] = {"Naxxramas", "Eye of Eternity", "Obsidian Sanctum"},
[14] = {"Ulduar"},
[15] = {"Trial of the Crusader"},
[16] = {"Icecrown Citadel"},
[17] = {"Ruby Sanctum"},
[18] = {"Tiers Complete"},
}
[0] = {PBM_L["Molten Core"], PBM_L["Onyxia's Lair"]},
[1] = {PBM_L["Molten Core"], PBM_L["Onyxia's Lair"]},
[2] = {PBM_L["Blackwing Lair"]},
[3] = {PBM_L["Ahn'Qiraj War Effort"]},
[4] = {PBM_L["AQ War"]},
[5] = {PBM_L["Ahn'Qiraj"], PBM_L["Ruins of Ahn'Qiraj"]},
[6] = {PBM_L["Naxxramas 40"]},
[7] = {PBM_L["Pre-TBC"]},
[8] = {PBM_L["Karazhan"], PBM_L["Gruul's Lair"], PBM_L["Magtheridon's Lair"]},
[9] = {PBM_L["Serpentshrine Cavern"], PBM_L["Tempest Keep"]},
[10] = {PBM_L["Mount Hyjal"], PBM_L["Black Temple"]},
[11] = {PBM_L["Zul'Aman (Optional)"]},
[12] = {PBM_L["Sunwell Plateau"]},
[13] = {PBM_L["Naxxramas"], PBM_L["Eye of Eternity"], PBM_L["Obsidian Sanctum"]},
[14] = {PBM_L["Ulduar"]},
[15] = {PBM_L["Trial of the Crusader"]},
[16] = {PBM_L["Icecrown Citadel"]},
[17] = {PBM_L["Ruby Sanctum"]},
[18] = {PBM_L["Tiers Complete"]},
}
72 changes: 36 additions & 36 deletions PBM/PBM_BotSettings.lua
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ function PBM.BuildBotSettingsFrame(parent, fl)
hdrTitle:SetPoint("TOPRIGHT", hdr, "TOPRIGHT", 0, 0)
hdrTitle:SetHeight(24)
hdrTitle:SetJustifyH("CENTER"); hdrTitle:SetJustifyV("MIDDLE")
hdrTitle:SetText("|cff7799ffBot Settings|r")
hdrTitle:SetText("|cff7799ff" .. PBM_L["Bot Settings"] .. "|r")

local BL = fl + 12 -- base frame level for content
local ROW_START = 52 -- top padding below header
Expand All @@ -136,20 +136,20 @@ function PBM.BuildBotSettingsFrame(parent, fl)
-- ============================================================
local COL1_X = 35

MakeLabel(f, "Add RndBot", COL1_X, ROW_START, BL)
MakeLabel(f, PBM_L["Add RndBot"], COL1_X, ROW_START, BL)
MakeDivider(f, COL1_X, ROW_START + 16, 220, BL)

local CLASS_DEFS = {
{ name = "Death Knight", cmd = "dk", hex = "C41F3B", icon = ADDON_PATH .. "addclass_deathknight.blp" },
{ name = "Druid", cmd = "druid", hex = "FF7D0A", icon = ADDON_PATH .. "addclass_druid.blp" },
{ name = "Hunter", cmd = "hunter", hex = "ABD473", icon = ADDON_PATH .. "addclass_hunter.blp" },
{ name = "Mage", cmd = "mage", hex = "3FC7EB", icon = ADDON_PATH .. "addclass_mage.blp" },
{ name = "Paladin", cmd = "paladin", hex = "F58CBA", icon = ADDON_PATH .. "addclass_paladin.blp" },
{ name = "Priest", cmd = "priest", hex = "FFFFFF", icon = ADDON_PATH .. "addclass_priest.blp" },
{ name = "Rogue", cmd = "rogue", hex = "FFF569", icon = ADDON_PATH .. "addclass_rogue.blp" },
{ name = "Shaman", cmd = "shaman", hex = "0070DE", icon = ADDON_PATH .. "addclass_shaman.blp" },
{ name = "Warlock", cmd = "warlock", hex = "8787ED", icon = ADDON_PATH .. "addclass_warlock.blp" },
{ name = "Warrior", cmd = "warrior", hex = "C79C3B", icon = ADDON_PATH .. "addclass_warrior.blp" },
{ name = PBM_L["Death Knight"], cmd = "dk", hex = "C41F3B", icon = ADDON_PATH .. "addclass_deathknight.blp" },
{ name = PBM_L["Druid"], cmd = "druid", hex = "FF7D0A", icon = ADDON_PATH .. "addclass_druid.blp" },
{ name = PBM_L["Hunter"], cmd = "hunter", hex = "ABD473", icon = ADDON_PATH .. "addclass_hunter.blp" },
{ name = PBM_L["Mage"], cmd = "mage", hex = "3FC7EB", icon = ADDON_PATH .. "addclass_mage.blp" },
{ name = PBM_L["Paladin"], cmd = "paladin", hex = "F58CBA", icon = ADDON_PATH .. "addclass_paladin.blp" },
{ name = PBM_L["Priest"], cmd = "priest", hex = "FFFFFF", icon = ADDON_PATH .. "addclass_priest.blp" },
{ name = PBM_L["Rogue"], cmd = "rogue", hex = "FFF569", icon = ADDON_PATH .. "addclass_rogue.blp" },
{ name = PBM_L["Shaman"], cmd = "shaman", hex = "0070DE", icon = ADDON_PATH .. "addclass_shaman.blp" },
{ name = PBM_L["Warlock"], cmd = "warlock", hex = "8787ED", icon = ADDON_PATH .. "addclass_warlock.blp" },
{ name = PBM_L["Warrior"], cmd = "warrior", hex = "C79C3B", icon = ADDON_PATH .. "addclass_warrior.blp" },
}

local classRowY = ROW_START + 24
Expand All @@ -158,7 +158,7 @@ function PBM.BuildBotSettingsFrame(parent, fl)
local classBtn = MakeIconBtn(f, COL1_X, classRowY,
cd.icon,
cd.name,
"Summon a random " .. cd.name .. " RndBot.", BL)
string.format(PBM_L["Summon a random %s RndBot."], cd.name), BL)

local capturedCmd = cd.cmd
classBtn:SetScript("OnClick", function()
Expand All @@ -177,112 +177,112 @@ function PBM.BuildBotSettingsFrame(parent, fl)
-- ============================================================
local COL2_X = 296

MakeLabel(f, "Bot Controls", COL2_X, ROW_START, BL)
MakeLabel(f, PBM_L["Bot Controls"], COL2_X, ROW_START, BL)
MakeDivider(f, COL2_X, ROW_START + 16, 220, BL)

local rowY = ROW_START + 24

-- ── Selfbot ──────────────────────────────────────────────
local selfbotBtn = MakeIconBtn(f, COL2_X, rowY,
ICON_PATH .. "inv_misc_head_clockworkgnome_01",
"Selfbot",
"Switches Selfbot mode on and off.\nLeft-click to toggle.", BL)
PBM_L["Selfbot"],
PBM_L["Switches Selfbot mode on and off.\nLeft-click to toggle."], BL)
WireToggle(selfbotBtn,
function() PBM.ActionToGroup("selfbot on") end,
function() PBM.ActionToGroup("selfbot off") end)

local selfLabel = f:CreateFontString(nil, "OVERLAY", "GameFontNormalSmall")
selfLabel:SetPoint("LEFT", selfbotBtn, "RIGHT", 6, 0)
selfLabel:SetText("|cffccccccSelfbot|r")
selfLabel:SetText("|cffcccccc" .. PBM_L["Selfbot"] .. "|r")

rowY = rowY + STEP

-- ── GameMaster Toggle ─────────────────────────────────────
local gmBtn = MakeIconBtn(f, COL2_X, rowY,
ICON_PATH .. "mail_gmicon",
"GameMaster Switch",
"Enable or disable GameMaster control.\nRequires GM rights.", BL)
PBM_L["GameMaster Switch"],
PBM_L["Enable or disable GameMaster control.\nRequires GM rights."], BL)
WireToggle(gmBtn,
function() PBM.ActionToGroup("gm on") end,
function() PBM.ActionToGroup("gm off") end)

local gmLabel = f:CreateFontString(nil, "OVERLAY", "GameFontNormalSmall")
gmLabel:SetPoint("LEFT", gmBtn, "RIGHT", 6, 0)
gmLabel:SetText("|cffccccccGameMaster|r")
gmLabel:SetText("|cffcccccc" .. PBM_L["GameMaster"] .. "|r")

rowY = rowY + STEP

-- ── RTSC Toggle ───────────────────────────────────────────
local rtscBtn = MakeIconBtn(f, COL2_X, rowY,
ICON_PATH .. "ability_hunter_markedfordeath",
"RTSC",
"Enable or disable RTSC.\nLeft-click to toggle.", BL)
PBM_L["RTSC"],
PBM_L["Enable or disable RTSC.\nLeft-click to toggle."], BL)
WireToggle(rtscBtn,
function() PBM.ActionToGroup("rtsc") end,
function() PBM.ActionToGroup("rtsc reset") end)

local rtscLabel = f:CreateFontString(nil, "OVERLAY", "GameFontNormalSmall")
rtscLabel:SetPoint("LEFT", rtscBtn, "RIGHT", 6, 0)
rtscLabel:SetText("|cffccccccRTSC|r")
rtscLabel:SetText("|cffcccccc" .. PBM_L["RTSC"] .. "|r")

rowY = rowY + STEP

-- ── Auto Release ──────────────────────────────────────────
local releaseBtn = MakeIconBtn(f, COL2_X, rowY,
ICON_PATH .. "achievement_bg_xkills_avgraveyard",
"Auto Release",
"Toggle automatic spirit release on bot death.", BL)
PBM_L["Auto Release"],
PBM_L["Toggle automatic spirit release on bot death."], BL)
WireToggle(releaseBtn,
function() PBM.ActionToGroup("release") end,
function() PBM.ActionToGroup("no release") end)

local relLabel = f:CreateFontString(nil, "OVERLAY", "GameFontNormalSmall")
relLabel:SetPoint("LEFT", releaseBtn, "RIGHT", 6, 0)
relLabel:SetText("|cffccccccAuto Release|r")
relLabel:SetText("|cffcccccc" .. PBM_L["Auto Release"] .. "|r")

rowY = rowY + STEP

-- ── Auto Stats ────────────────────────────────────────────
local statsBtn = MakeIconBtn(f, COL2_X, rowY,
ICON_PATH .. "inv_scroll_08",
"Auto Stats",
"Toggle automatic stats broadcast to group.", BL)
PBM_L["Auto Stats"],
PBM_L["Toggle automatic stats broadcast to group."], BL)
WireToggle(statsBtn,
function() PBM.ActionToGroup("stats on") end,
function() PBM.ActionToGroup("stats off") end)

local statsLabel = f:CreateFontString(nil, "OVERLAY", "GameFontNormalSmall")
statsLabel:SetPoint("LEFT", statsBtn, "RIGHT", 6, 0)
statsLabel:SetText("|cffccccccAuto Stats|r")
statsLabel:SetText("|cffcccccc" .. PBM_L["Auto Stats"] .. "|r")

rowY = rowY + STEP

-- ── Reset Bot AI ──────────────────────────────────────────
local resetAIBtn = MakeIconBtn(f, COL2_X, rowY,
ICON_PATH .. "inv_misc_tournaments_symbol_gnome",
"Reset Bot AI",
"Reset AI for targeted bot or entire group.", BL)
PBM_L["Reset Bot AI"],
PBM_L["Reset AI for targeted bot or entire group."], BL)
resetAIBtn:SetScript("OnClick", function()
PBM.ActionToTargetOrGroup("reset botAI")
end)

local resetAILabel = f:CreateFontString(nil, "OVERLAY", "GameFontNormalSmall")
resetAILabel:SetPoint("LEFT", resetAIBtn, "RIGHT", 6, 0)
resetAILabel:SetText("|cffccccccReset Bot AI|r")
resetAILabel:SetText("|cffcccccc" .. PBM_L["Reset Bot AI"] .. "|r")

rowY = rowY + STEP

-- ── Reset Action ──────────────────────────────────────────
local resetActBtn = MakeIconBtn(f, COL2_X, rowY,
ICON_PATH .. "inv_helmet_02",
"Reset Action",
"Reset actions for targeted bot or entire group.", BL)
PBM_L["Reset Action"],
PBM_L["Reset actions for targeted bot or entire group."], BL)
resetActBtn:SetScript("OnClick", function()
PBM.ActionToTargetOrGroup("reset")
end)

local resetActLabel = f:CreateFontString(nil, "OVERLAY", "GameFontNormalSmall")
resetActLabel:SetPoint("LEFT", resetActBtn, "RIGHT", 6, 0)
resetActLabel:SetText("|cffccccccReset Action|r")
resetActLabel:SetText("|cffcccccc" .. PBM_L["Reset Action"] .. "|r")

end
end
14 changes: 7 additions & 7 deletions PBM/PBM_BottomTabs.lua
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ local BD_CELL = {

-- ── Tab definitions (colors match LT exactly) ─────────────────
local BOTTOM_TABS = {
{ id="Playerbots", label="Playerbots", r=PERI_R, g=PERI_G, b=PERI_B },
{ id="LevelSync", label="LevelSync", r=GOLD_R, g=GOLD_G, b=GOLD_B },
{ id="Notes", label="Notes", r=GOLD_R, g=GOLD_G, b=GOLD_B },
{ id="Playerbots", label=PBM_L["Playerbots"], r=PERI_R, g=PERI_G, b=PERI_B },
{ id="LevelSync", label=PBM_L["LevelSync"], r=GOLD_R, g=GOLD_G, b=GOLD_B },
{ id="Notes", label=PBM_L["Notes"], r=GOLD_R, g=GOLD_G, b=GOLD_B },
}

-- ── Tab button layout (title bar row, right of Clear buttons) ─
Expand Down Expand Up @@ -175,17 +175,17 @@ function PBM.BuildBottomTabs(parent, fl)
}

-- ── Playerbots panel ─────────────────────────────────────
local pbPanel = MakeContentFrame("PBMTabPanel_Playerbots", parent, fl, "Playerbots", false)
local pbPanel = MakeContentFrame("PBMTabPanel_Playerbots", parent, fl, PBM_L["Playerbots"], false)
PBM.State.bottomTabPanels["Playerbots"] = pbPanel
PBM.BuildPlayerbotsPanel(pbPanel, ctx)

-- ── LevelSync panel (gold header, full height) ────────────
local lsPanel = MakeContentFrame("PBMTabPanel_LevelSync", parent, fl, "LevelSync", true, GOLD_R, GOLD_G, GOLD_B)
local lsPanel = MakeContentFrame("PBMTabPanel_LevelSync", parent, fl, PBM_L["LevelSync"], true, GOLD_R, GOLD_G, GOLD_B)
PBM.State.bottomTabPanels["LevelSync"] = lsPanel
PBM.BuildLevelSyncPanel(lsPanel, ctx)

-- ── Notes panel (gold header) ─────────────────────────────
local notesPanel = MakeContentFrame("PBMTabPanel_Notes", parent, fl, "Notes", false, GOLD_R, GOLD_G, GOLD_B)
local notesPanel = MakeContentFrame("PBMTabPanel_Notes", parent, fl, PBM_L["Notes"], false, GOLD_R, GOLD_G, GOLD_B)
PBM.State.bottomTabPanels["Notes"] = notesPanel
PBM.BuildNotesPanel(notesPanel, ctx)

Expand Down Expand Up @@ -226,4 +226,4 @@ function PBM.BuildBottomTabs(parent, fl)
end

PBM.UpdateBottomTabHighlights()
end
end
Loading