Quantcast

Changed weapon damage to melee damage in meta gems effects

Kevin Lyles [02-19-10 - 02:41]
Changed weapon damage to melee damage in meta gems effects
Filename
GemIds.lua
Upgrade.lua
defaults.lua
diff --git a/GemIds.lua b/GemIds.lua
index b81250f..9bf9fae 100644
--- a/GemIds.lua
+++ b/GemIds.lua
@@ -457,7 +457,7 @@ GemIds = {
 				[2834] = {
 					"Meta",
 					"Brutal Earthstorm Diamond",
-					{["Weapon Damage"] = 3, ["Chance to Stun Target"] = 1},
+					{["Melee Damage"] = 3, ["Chance to Stun Target"] = 1},
 				},
 				[2835] = {
 					"Meta",
diff --git a/Upgrade.lua b/Upgrade.lua
index 5d90fda..1c46955 100644
--- a/Upgrade.lua
+++ b/Upgrade.lua
@@ -135,6 +135,18 @@ function noop_major_up(vars)
 	return vars
 end

+function upgradeAccountToWorkingMeleeDamage(vars)
+	for _, class in ipairs(vars.weightsList) do
+		for _, weight in ipairs(vars.weightsList[class]) do
+			vars.weightsList[class][weight]["melee damage"] = vars.weightsList[class][weight]["weapon damage"]
+			vars.weightsList[class][weight]["weapon damage"] = nil
+		end
+	end
+
+	vars.dataMinorVersion = 10
+	return vars
+end
+
 function upgradeAccountToWorkingResistances(vars)
 	local resistances = {
 		"arcane",
@@ -779,6 +791,7 @@ upgradeAccountFunctions = {
 		[6] = upgradeAccountToShowAlternateGems,
 		[7] = upgradeAccountToShowAlternateGemsTypoFix,
 		[8] = upgradeAccountToWorkingResistances,
+		[9] = upgradeAccountToWorkingMeleeDamage,
 	},
 }

@@ -805,6 +818,7 @@ downgradeAccountFunctions = {
 		[7] = noop_down,
 		[8] = noop_down,
 		[9] = noop_down,
+		[10] = noop_down,
 	},
 }

diff --git a/defaults.lua b/defaults.lua
index 6f01190..1eef839 100644
--- a/defaults.lua
+++ b/defaults.lua
@@ -53,6 +53,7 @@ trackedStats = {
 		"Fear Duration Reduction (Percent)",
 		"Intellect (Percent)",
 		"Mana (Percent)",
+		"Melee Damage",
 		"Minor Run Speed",
 		"Silence Duration Reduction (Percent)",
 		"Snare/Root Duration Reduction (Percent)",
@@ -62,7 +63,6 @@ trackedStats = {
 		"Stun Duration Reduction (Percent)",
 		"Stun Resistance (Percent)",
 		"Threat Reduction (Percent)",
-		"Weapon Damage",
 	},
 	["Resistances"] = {
 		"Arcane",
@@ -139,7 +139,7 @@ classNameOptions = {

 defaultVars = {
 	dataMajorVersion = 1,
-	dataMinorVersion = 9,
+	dataMinorVersion = 10,
 	weightsList = {
 		[1] = "DEATHKNIGHT",
 		[2] = "DRUID",