add zhCN locale

This commit is contained in:
jilinge2
2024-09-27 14:12:07 +08:00
parent 883d3459be
commit 803fccb9f7
12 changed files with 610 additions and 318 deletions
+63 -62
View File
@@ -1,19 +1,20 @@
local curseCommands = "|cffffcc00Cursive:|cffffaaaa Commands:"
local priorityChoices = "Priority choices:"
local curseOptions = "Options (separate with ,):"
local L = AceLibrary("AceLocale-2.2"):new("Cursive")
local curseCommands = L["|cffffcc00Cursive:|cffffaaaa Commands:"]
local priorityChoices = L["|cffffcc00Priority choices:"]
local curseOptions = L["|cffffcc00Options (separate with ,):"]
local commandOptions = {
warnings = "Display text warnings when a curse fails to cast.",
resistsound = "Play a sound when a curse is resisted.",
expiringsound = "Play a sound when a curse is about to expire.",
allowooc = "Allow out of combat targets to be multicursed. Would only consider using this solo to avoid potentially griefing raids/dungeons by pulling unintended mobs.",
minhp = "Minimum HP for a target to be considered. Example usage minhp=10000. ",
refreshtime = "Time threshold at which to allow refreshing a curse. Default is 0 seconds."
warnings = L["Display text warnings when a curse fails to cast."],
resistsound = L["Play a sound when a curse is resisted."],
expiringsound = L["Play a sound when a curse is about to expire."],
allowooc = L["Allow out of combat targets to be multicursed. Would only consider using this solo to avoid potentially griefing raids/dungeons by pulling unintended mobs."],
minhp = L["Minimum HP for a target to be considered. Example usage minhp=10000. "],
refreshtime = L["Time threshold at which to allow refreshing a curse. Default is 0 seconds."]
}
local commands = {
["curse"] = "/cursive curse <spellName:str>|<guid?:str>|<options?:List<str>>: Casts spell if not already on target/guid",
["multicurse"] = "/cursive multicurse <spellName:str>|<priority?:str>|<options?:List<str>>: Picks target based on priority and casts spell if not already on target",
["curse"] = L["/cursive curse <spellName:str>|<guid?:str>|<options?:List<str>>: Casts spell if not already on target/guid"],
["multicurse"] = L["/cursive multicurse <spellName:str>|<priority?:str>|<options?:List<str>>: Picks target based on priority and casts spell if not already on target"],
}
local PRIORITY_HIGHEST_HP = "HIGHEST_HP"
@@ -25,16 +26,16 @@ local PRIORITY_HIGHEST_HP_RAID_MARK_SQUARE = "HIGHEST_HP_RAID_MARK_SQUARE"
local PRIORITY_HIGHEST_HP_INVERSE_RAID_MARK = "HIGHEST_HP_INVERSE_RAID_MARK"
local priorities = {
[PRIORITY_HIGHEST_HP] = "Target with the highest HP.",
[PRIORITY_RAID_MARK] = "Target with the highest raid mark.",
[PRIORITY_RAID_MARK_SQUARE] = "Target with the highest raid mark with Cross set to -1 and Skull set to -2 (Square highest prio at 6).",
[PRIORITY_INVERSE_RAID_MARK] = "Target with the lowest raid mark.",
[PRIORITY_HIGHEST_HP_RAID_MARK] = "Target with the highest HP and raid mark.",
[PRIORITY_HIGHEST_HP_RAID_MARK_SQUARE] = "Same as HIGHEST_HP_RAID_MARK but with RAID_MARK_SQUARE mark prio.",
[PRIORITY_HIGHEST_HP_INVERSE_RAID_MARK] = "Same as HIGHEST_HP_RAID_MARK but with INVERSE_RAID_MARK mark prio."
[PRIORITY_HIGHEST_HP] = L["Target with the highest HP."],
[PRIORITY_RAID_MARK] = L["Target with the highest raid mark."],
[PRIORITY_RAID_MARK_SQUARE] = L["Target with the highest raid mark with Cross set to -1 and Skull set to -2 (Square highest prio at 6)."],
[PRIORITY_INVERSE_RAID_MARK] = L["Target with the lowest raid mark."],
[PRIORITY_HIGHEST_HP_RAID_MARK] = L["Target with the highest HP and raid mark."],
[PRIORITY_HIGHEST_HP_RAID_MARK_SQUARE] = L["Same as HIGHEST_HP_RAID_MARK but with RAID_MARK_SQUARE mark prio."],
[PRIORITY_HIGHEST_HP_INVERSE_RAID_MARK] = L["Same as HIGHEST_HP_RAID_MARK but with INVERSE_RAID_MARK mark prio."]
}
local curseNoTarget = "|cffffcc00Cursive:|cffffaaaa Couldn't find a target to curse."
local curseNoTarget = L["|cffffcc00Cursive:|cffffaaaa Couldn't find a target to curse."]
local function parseOptions(optionsStr)
local options = { }
@@ -69,12 +70,12 @@ local function handleSlashCommands(msg, editbox)
end
DEFAULT_CHAT_FRAME:AddMessage(priorityChoices)
for priority, description in pairs(priorities) do
DEFAULT_CHAT_FRAME:AddMessage(priority .. ": " .. description)
DEFAULT_CHAT_FRAME:AddMessage("|CFFFFFF00"..priority .. "|R: " .. description)
end
DEFAULT_CHAT_FRAME:AddMessage(curseOptions)
for option, description in pairs(commandOptions) do
DEFAULT_CHAT_FRAME:AddMessage(option .. ": " .. description)
DEFAULT_CHAT_FRAME:AddMessage("|CFFFFFF00"..option .. "|R: " .. description)
end
return
end
@@ -92,58 +93,58 @@ local function handleSlashCommands(msg, editbox)
end
local crowdControlledSpellIds = {
[700] = { name = "Sleep", rank = 1, duration = 20 },
[1090] = { name = "Sleep", rank = 2, duration = 30 },
[2937] = { name = "Sleep", rank = 3, duration = 40 },
[700] = { name = L["Sleep"], rank = 1, duration = 20 },
[1090] = { name = L["Sleep"], rank = 2, duration = 30 },
[2937] = { name = L["Sleep"], rank = 3, duration = 40 },
[339] = { name = "Entangling Roots", rank = 1, duration = 12 },
[1062] = { name = "Entangling Roots", rank = 2, duration = 15 },
[5195] = { name = "Entangling Roots", rank = 3, duration = 18 },
[5196] = { name = "Entangling Roots", rank = 4, duration = 21 },
[9852] = { name = "Entangling Roots", rank = 5, duration = 24 },
[9853] = { name = "Entangling Roots", rank = 6, duration = 27 },
[339] = { name = L["Entangling Roots"], rank = 1, duration = 12 },
[1062] = { name = L["Entangling Roots"], rank = 2, duration = 15 },
[5195] = { name = L["Entangling Roots"], rank = 3, duration = 18 },
[5196] = { name = L["Entangling Roots"], rank = 4, duration = 21 },
[9852] = { name = L["Entangling Roots"], rank = 5, duration = 24 },
[9853] = { name = L["Entangling Roots"], rank = 6, duration = 27 },
[2637] = { name = "Hibernate", rank = 1, duration = 20 },
[18657] = { name = "Hibernate", rank = 2, duration = 30 },
[18658] = { name = "Hibernate", rank = 3, duration = 40 },
[2637] = { name = L["Hibernate"], rank = 1, duration = 20 },
[18657] = { name = L["Hibernate"], rank = 2, duration = 30 },
[18658] = { name = L["Hibernate"], rank = 3, duration = 40 },
[1425] = { name = "Shackle Undead", rank = 1, duration = 30 },
[9486] = { name = "Shackle Undead", rank = 2, duration = 40 },
[10956] = { name = "Shackle Undead", rank = 3, duration = 50 },
[1425] = { name = L["Shackle Undead"], rank = 1, duration = 30 },
[9486] = { name = L["Shackle Undead"], rank = 2, duration = 40 },
[10956] = { name = L["Shackle Undead"], rank = 3, duration = 50 },
-- polymorph
[118] = { name = "Polymorph", rank = "Rank 1", duration = 20 },
[12824] = { name = "Polymorph", rank = "Rank 2", duration = 30 },
[12825] = { name = "Polymorph", rank = "Rank 3", duration = 40 },
[12826] = { name = "Polymorph", rank = "Rank 4", duration = 50 },
[118] = { name = L["Polymorph"], rank = L["Rank 1"], duration = 20 },
[12824] = { name = L["Polymorph"], rank = L["Rank 2"], duration = 30 },
[12825] = { name = L["Polymorph"], rank = L["Rank 3"], duration = 40 },
[12826] = { name = L["Polymorph"], rank = L["Rank 4"], duration = 50 },
[28270] = { name = "Polymorph: Cow", rank = "Rank 1", duration = 50 },
[28271] = { name = "Polymorph: Turtle", rank = "Rank 1", duration = 50 },
[28272] = { name = "Polymorph: Pig", rank = "Rank 1", duration = 50 },
[28270] = { name = L["Polymorph: Cow"], rank = L["Rank 1"], duration = 50 },
[28271] = { name = L["Polymorph: Turtle"], rank = L["Rank 1"], duration = 50 },
[28272] = { name = L["Polymorph: Pig"], rank = L["Rank 1"], duration = 50 },
[2878] = { name = "Turn Undead", rank = 1, duration = 10 },
[5627] = { name = "Turn Undead", rank = 2, duration = 15 },
[10326] = { name = "Turn Undead", rank = 3, duration = 20 },
[2878] = { name = L["Turn Undead"], rank = 1, duration = 10 },
[5627] = { name = L["Turn Undead"], rank = 2, duration = 15 },
[10326] = { name = L["Turn Undead"], rank = 3, duration = 20 },
[2094] = { name = "Blind", rank = 1, duration = 10 },
[21060] = { name = "Blind", rank = 1, duration = 10 },
[2094] = { name = L["Blind"], rank = 1, duration = 10 },
[21060] = { name = L["Blind"], rank = 1, duration = 10 },
[6770] = { name = "Sap", rank = 1, duration = 25 },
[2070] = { name = "Sap", rank = 2, duration = 35 },
[11297] = { name = "Sap", rank = 3, duration = 45 },
[6770] = { name = L["Sap"], rank = 1, duration = 25 },
[2070] = { name = L["Sap"], rank = 2, duration = 35 },
[11297] = { name = L["Sap"], rank = 3, duration = 45 },
[1776] = { name = "Gouge", rank = 1, duration = 4 },
[1777] = { name = "Gouge", rank = 2, duration = 4 },
[8629] = { name = "Gouge", rank = 3, duration = 4 },
[11285] = { name = "Gouge", rank = 4, duration = 4 },
[11286] = { name = "Gouge", rank = 5, duration = 4 },
[1776] = { name = L["Gouge"], rank = 1, duration = 4 },
[1777] = { name = L["Gouge"], rank = 2, duration = 4 },
[8629] = { name = L["Gouge"], rank = 3, duration = 4 },
[11285] = { name = L["Gouge"], rank = 4, duration = 4 },
[11286] = { name = L["Gouge"], rank = 5, duration = 4 },
[3355] = { name = "Freezing Trap", rank = 1, duration = 10 },
[14308] = { name = "Freezing Trap", rank = 2, duration = 15 },
[14309] = { name = "Freezing Trap", rank = 3, duration = 20 },
[3355] = { name = L["Freezing Trap"], rank = 1, duration = 10 },
[14308] = { name = L["Freezing Trap"], rank = 2, duration = 15 },
[14309] = { name = L["Freezing Trap"], rank = 3, duration = 20 },
[710] = { name = "Banish", rank = 1, duration = 30 },
[18647] = { name = "Banish", rank = 2, duration = 30 },
[710] = { name = L["Banish"], rank = 1, duration = 30 },
[18647] = { name = L["Banish"], rank = 2, duration = 30 },
}
local function isMobCrowdControlled(guid)
@@ -317,7 +318,7 @@ function Cursive:Multicurse(spellName, priority, options)
if priority and not priorities[priority] then
DEFAULT_CHAT_FRAME:AddMessage(priorityChoices)
for choice, description in pairs(priorities) do
DEFAULT_CHAT_FRAME:AddMessage(choice .. ": " .. description)
DEFAULT_CHAT_FRAME:AddMessage("|CFFFFFF00"..choice .. "|R: " .. description)
end
return
end