diff --git a/index.js b/index.js index 4af23cd..8f01318 100644 --- a/index.js +++ b/index.js @@ -40,222 +40,7 @@ var optimizer = require("bindings")("swtor_tanking_optimizer.node") , useKW: 0 } } - , relicData = { - arkanian: { //to fix - redoubt: { - type: 1 //proc - , stat: 1 //defense - , rating: 510 - , rate: 0.30 - , duration: 6 - , cooldown: 20 - , can_stack: 0 - } - , shield_amp: { - type: 1 //proc - , stat: 3 //absorb - , rating: 510 - , rate: 1.0 - , duration: 6 - , cooldown: 20 - , can_stack: 0 - } - , imperiling: { - type: 2 //click - , stat1: 1 //defense - , stat2: 0 //none - , rating1: 395 - , rating2: 0 - , duration: 20 - , cooldown: 120 //confirm? - } - , shrouded: { - type: 2 //click - , stat1: 2 //shield - , stat2: 3 //absorb - , rating1: 245 - , rating2: 245 - , duration: 20 - , cooldown: 120 //confirm? - } - } - , underworld: { - redoubt: { - type: 1 //proc - , stat: 1 //defense - , rating: 550 - , rate: 0.30 - , duration: 6 - , cooldown: 20 - , can_stack: 0 - } - , shield_amp: { - type: 1 //proc - , stat: 3 //absorb - , rating: 550 - , rate: 1.0 - , duration: 6 - , cooldown: 20 - , can_stack: 0 - } - , imperiling: { - type: 2 //click - , stat1: 1 //defense - , stat2: 0 //none - , rating1: 425 - , rating2: 0 - , duration: 20 - , cooldown: 120 //confirm? - } - , shrouded: { - type: 2 //click - , stat1: 2 //shield - , stat2: 3 //absorb - , rating1: 265 - , rating2: 265 - , duration: 20 - , cooldown: 120 //confirm? - } - } - , dreadguard: { - redoubt: { - type: 1 //proc - , stat: 1 //defense - , rating: 455 - , rate: 0.30 - , duration: 6 - , cooldown: 20 - , can_stack: 0 - } - , shield_amp: { - type: 1 //proc - , stat: 3 //absorb - , rating: 455 - , rate: 1.0 - , duration: 6 - , cooldown: 20 - , can_stack: 0 - } - , imperiling: { - type: 2 //click - , stat1: 1 //defense - , stat2: 0 //none - , rating1: 350 - , rating2: 0 - , duration: 20 - , cooldown: 120 //confirm? - } - , shrouded: { - type: 2 //click - , stat1: 2 //shield - , stat2: 3 //absorb - , rating1: 215 - , rating2: 215 - , duration: 20 - , cooldown: 120 //confirm? - } - } - , campaign: { - redoubt: { - type: 1 //proc - , stat: 1 //defense - , rating: 415 //not verified - , rate: 0.30 - , duration: 6 - , cooldown: 20 - , can_stack: 0 - } - , shield_amp: { - type: 1 //proc - , stat: 3 //absorb - , rating: 415 //not verified - , rate: 1.0 - , duration: 6 - , cooldown: 20 - , can_stack: 0 - } - , imperiling: { - type: 2 //click - , stat1: 1 //defense - , stat2: 0 //none - , rating1: 315 - , rating2: 0 - , duration: 20 - , cooldown: 120 //confirm? - } - , shrouded: { - type: 2 //click - , stat1: 2 //shield - , stat2: 3 //absorb - , rating1: 190 - , rating2: 190 - , duration: 20 - , cooldown: 120 //confirm? - } - } - , partisan: { - redoubt: { - type: 1 //proc - , stat: 1 //defense - , rating: 410 - , rate: 0.30 - , duration: 6 - , cooldown: 20 - , can_stack: 1 - } - , shield_amp: { - type: 1 //proc - , stat: 3 //absorb - , rating: 410 - , rate: 1.0 - , duration: 6 - , cooldown: 20 - , can_stack: 1 - } - } - , conqueror: { - redoubt: { - type: 1 //proc - , stat: 1 //defense - , rating: 435 - , rate: 0.30 - , duration: 6 - , cooldown: 20 - , can_stack: 1 - } - , shield_amp: { - type: 1 //proc - , stat: 3 //absorb - , rating: 435 - , rate: 1.0 - , duration: 6 - , cooldown: 20 - , can_stack: 1 - } - } - , elitewarhero: { - shield_amp: { - type: 1 //proc - , stat: 3 //absorb - , rating: 430 - , rate: 1.0 - , duration: 6 - , cooldown: 20 - , can_stack: 0 - } - } - , warhero: { - shield_amp: { - type: 1 //proc - , stat: 3 //absorb - , rating: 405 - , rate: 1.0 - , duration: 6 - , cooldown: 20 - , can_stack: 0 - } - } - } + , relicData = require("./relics") //The following data is from http://www.swtor.com/community/showthread.php?t=616779 , otherData = { dmgMRKE: 0.7793 //defendable KE damage percent @@ -268,10 +53,7 @@ var optimizer = require("bindings")("swtor_tanking_optimizer.node") ; module.exports = { - optimize: function (klass, startingStats, armor, callback){ - optimizer.optimize(otherData, classData[klass], {numRelics: 0}, startingStats, armor, 70, callback); - } -, optimizer: optimizer + optimizer: optimizer , classData: classData , otherData: otherData , relicData: relicData diff --git a/relics.js b/relics.js new file mode 100644 index 0000000..6b9158a --- /dev/null +++ b/relics.js @@ -0,0 +1,216 @@ +module.exports = { + arkanian: { + redoubt: { + type: 1 //proc + , stat: 1 //defense + , rating: 510 + , rate: 0.30 + , duration: 6 + , cooldown: 20 + , can_stack: 0 + } + , shield_amp: { + type: 1 //proc + , stat: 3 //absorb + , rating: 510 + , rate: 1.0 + , duration: 6 + , cooldown: 20 + , can_stack: 0 + } + , imperiling: { + type: 2 //click + , stat1: 1 //defense + , stat2: 0 //none + , rating1: 395 + , rating2: 0 + , duration: 20 + , cooldown: 120 //confirm? + } + , shrouded: { + type: 2 //click + , stat1: 2 //shield + , stat2: 3 //absorb + , rating1: 245 + , rating2: 245 + , duration: 20 + , cooldown: 120 //confirm? + } + } +, underworld: { + redoubt: { + type: 1 //proc + , stat: 1 //defense + , rating: 550 + , rate: 0.30 + , duration: 6 + , cooldown: 20 + , can_stack: 0 + } + , shield_amp: { + type: 1 //proc + , stat: 3 //absorb + , rating: 550 + , rate: 1.0 + , duration: 6 + , cooldown: 20 + , can_stack: 0 + } + , imperiling: { + type: 2 //click + , stat1: 1 //defense + , stat2: 0 //none + , rating1: 425 + , rating2: 0 + , duration: 20 + , cooldown: 120 //confirm? + } + , shrouded: { + type: 2 //click + , stat1: 2 //shield + , stat2: 3 //absorb + , rating1: 265 + , rating2: 265 + , duration: 20 + , cooldown: 120 //confirm? + } + } +, dreadguard: { + redoubt: { + type: 1 //proc + , stat: 1 //defense + , rating: 455 + , rate: 0.30 + , duration: 6 + , cooldown: 20 + , can_stack: 0 + } + , shield_amp: { + type: 1 //proc + , stat: 3 //absorb + , rating: 455 + , rate: 1.0 + , duration: 6 + , cooldown: 20 + , can_stack: 0 + } + , imperiling: { + type: 2 //click + , stat1: 1 //defense + , stat2: 0 //none + , rating1: 350 + , rating2: 0 + , duration: 20 + , cooldown: 120 //confirm? + } + , shrouded: { + type: 2 //click + , stat1: 2 //shield + , stat2: 3 //absorb + , rating1: 215 + , rating2: 215 + , duration: 20 + , cooldown: 120 //confirm? + } + } +, campaign: { + redoubt: { + type: 1 //proc + , stat: 1 //defense + , rating: 415 //not verified + , rate: 0.30 + , duration: 6 + , cooldown: 20 + , can_stack: 0 + } + , shield_amp: { + type: 1 //proc + , stat: 3 //absorb + , rating: 415 //not verified + , rate: 1.0 + , duration: 6 + , cooldown: 20 + , can_stack: 0 + } + , imperiling: { + type: 2 //click + , stat1: 1 //defense + , stat2: 0 //none + , rating1: 315 + , rating2: 0 + , duration: 20 + , cooldown: 120 //confirm? + } + , shrouded: { + type: 2 //click + , stat1: 2 //shield + , stat2: 3 //absorb + , rating1: 190 + , rating2: 190 + , duration: 20 + , cooldown: 120 //confirm? + } + } +, partisan: { + redoubt: { + type: 1 //proc + , stat: 1 //defense + , rating: 410 + , rate: 0.30 + , duration: 6 + , cooldown: 20 + , can_stack: 1 + } + , shield_amp: { + type: 1 //proc + , stat: 3 //absorb + , rating: 410 + , rate: 1.0 + , duration: 6 + , cooldown: 20 + , can_stack: 1 + } + } +, conqueror: { + redoubt: { + type: 1 //proc + , stat: 1 //defense + , rating: 435 + , rate: 0.30 + , duration: 6 + , cooldown: 20 + , can_stack: 1 + } + , shield_amp: { + type: 1 //proc + , stat: 3 //absorb + , rating: 435 + , rate: 1.0 + , duration: 6 + , cooldown: 20 + , can_stack: 1 + } + } +, elitewarhero: { + shield_amp: { + type: 1 //proc + , stat: 3 //absorb + , rating: 430 + , rate: 1.0 + , duration: 6 + , cooldown: 20 + , can_stack: 0 + } + } +, warhero: { + shield_amp: { + type: 1 //proc + , stat: 3 //absorb + , rating: 405 + , rate: 1.0 + , duration: 6 + , cooldown: 20 + , can_stack: 0 + } + } +};