Current script state:WORKING
To do list:
Write a better poison function, that will only poison once an hour, and won't try to re-apply poison after dying.
Start using melee stealth opener when ammo runs out.
Here is the food macro, if you don't have shadowmeld, you're out of luck, you will die 5x more than nightelves when you vanish, unless you pull the mob, and he runs away after you vanish. That's because 5 seconds after vanishing, character will try to eat, with shadowmeld he will go invisible, other races aren't so fortunate though.
(Remember to change the type of food)
Code:
#show Soft Banana Bread
#showtooltip
/use Soft Banana Bread
/cast Shadowmeld
Blind macro.
(Remember to adjust bandages to the ones you use!)
Code:
#show Blind
#showtooltip
/cast Blind
/use [target=player] Heavy Netherweave Bandage
Here it is!
Code:
## Ferocity v.03a
## Friday, September 26, 2008
## v.03 changelog
# v.a
# Added flurry feature
### Reach settings
## Ranged
engage_dist=28
reach=28
maxreach=30
## Melee
#engage_dist=24
#reach=4
#maxreach=30
### Resting settings
FOODPERCENT=0.50
HEALTHRESTPERCENT=0.50
HEALTHRESTTOPERCENT=0.95
DRINKPERCENT=0
MANARESTPERCENT=0
MANARESTTOPERCENT=0
### Key and actions definitions
## Settings
defact= act:stealth key:` slot:key
defact= act:fight key:t slot:key
defact= act:pull key:= slot:1 js:checkpull()
# Note, the name is hemo because that's what I use, if you use sinister strike, just adjust the energy cost in the
script section.
defact= act:hemo slot:1 key:1 cooldown:1 js:checkhemo()
defact= act:evis slot:1 key:2 cooldown:1 js:checkevis()
defact= act:evasion slot:1 key:9 prevacttime:300 js:checkevasion()
defact= act:vanish slot:1 prevacttime:300 key:8
defact= act:food slot:1 key:7 cooldown:1
defact= act:bandage slot:1 prevacttime:300 key:6
defact= act:flurry slot:1 key:3 prevacttime:120 js:checkflurry()
defact= act:poisonmh slot:1 key:0 prevacttime:10
defact= act:poisonoh slot:1 key:- prevacttime:10
## Don't touch these unless you know what you're doing
defact= act:display js:displayinfo()
defact= act:checkbandage js:checkbandage()
defact= act:checkvanish js:checkvanish()
defact= act:stoprun js:wowjs.wowStopRun()
defact= act:approach predefined:approach distge:4 dist:4 approachcheck:checkApproachTarget()
defact= act:wait1s cooldown:1 distle:5
defact= act:lootapproach predefined:lootapproach distle:25 distge:5 dist:5
defact= act:reachCombat js:ReachCombatDistance()
defact= act:loot predefined:loot distle:5 js:lootable()
defact= act:pullwait js:waitpull()
## Global
-globalact= act:poisonmh timeout:61m
-globalact= act:poisonoh timeout:62m
### Combat sequences
## Pre
# Disable pull and wait if you're not pulling!
-precombat= act:stealth
# I'm not enabling stealth because I pull to engage, instead of engaging in melee, suggested to turn it on if you're
not going to use melee.
precombat= act:pull
precombat= act:pullwait
precombat= act:approach
precombat= act:stoprun
precombat= act:fight
## During
combatseq= act:checkvanish
combatseq= act:checkbandage
combatseq= act:evasion
combatseq= act:approach
combatseq= act:hemo
combatseq= act:evis
combatseq= act:flurry
## After
lootseq= act:lootapproach
lootseq= act:wait1s
lootseq= act:loot
lootseq= act:wait1s
lootseq= act:wait1s
### Script
<script>
// Energy cost of your main attack.
var energycost = 35;
// What percentage of health to get to before vanishing.
var percenttovanish = 0.1;
// What percentage of health to get to before using evasion, note, it will only use it if you're fighting more than one monster, this is more of an emergency ability, along with vanish.
var percenttoevade = 0.45;
// What percentage of health to blind and use bandage on yourself.
var percenttobandage = 0.25;
// Do not adjust below unless you know what you're doing!
var combos = 0;
var pulled = false;
function checkevis(){
if (me.energy > 35 && combos > 4){
wowjs.wowLog("Have 5 combo points and enough energy, eviscerating.");
combos = 0;
return true;
}
return false;
}
function checkhemo(){
if (combos > 4 || me.energy < energycost) return false;
combos++;
wowjs.wowLog("Using hemo, new combo points number is: " + combos + ".");
return true;
}
function checkbandage(){
var lifepercent = me.health / me.maxhealth;
if (lifepercent > percenttobandage) return;
var attacking = me.wowGetAttackingMobs();
var attackingnumber = 0;
var done = 0;
var i = 0;
while (done != 1) {
if (attacking[i] != null) {
attackingnumber++;
}else {
done = 1;
}
i++;
}
if (attackingnumber == 1) {
wowjs.wowLog("Only one mob is attacking me, and I am below needed health, blinding and bandaging myself.");
me.wowDoFightAction("bandage");
var y = 0;
while (y < 40) {
if (me.inCombat == true) return;
me.wowSleep(200);
y++;
}
return;
}
return;
}
function checkevasion(){
var lifepercent = me.health / me.maxhealth;
if (lifepercent > percenttoevade) return false;
var attacking = me.wowGetAttackingMobs();
var attackingnumber = 0;
var done = 0;
var i = 0;
while (done != 1) {
if (attacking[i] != null) {
attackingnumber++;
}else{
done = 1;
}
i++;
}
if (attackingnumber > 1) return true;
return false;
}
function checkvanish(){
var lifepercent = me.health / me.maxhealth;
if (lifepercent <= percenttovanish) {
wowjs.wowLog("Below needed health, vanishing.");
me.wowDoFightAction("vanish");
me.wowSleep(5000);
me.wowdoFightAction("stealth");
me.wowDoFightAction("food");
var vanishto = 0;
while (lifepercent < 0.9) {
vanishto++;
me.wowSleep(100);
lifepercent = me.health / me.maxhealth;
if (lifepercent == 0) return;
if (me.inCombat == true) return;
if (vanishto > 300) return;
}
wowjs.wowAbortCurFight = true;
}
}
function checkpull(){
var target = me.target;
var distance = Math.sqrt(Math.pow(target.x-me.x,2)+Math.pow(target.y-me.y,2));
if (distance < 0) distance * -1;
if (distance > 5) {
wowjs.wowLog("Monster is more than 5 yards away,pulling.");
pulled = true;
return true;
}
wowjs.wowLog("Monster is in melee range, no need to pull.");
pulled = false;
return false;
}
function waitpull(){
if (pulled == true) {
var target = me.target;
var distance = Math.sqrt(Math.pow(target.x - me.x, 2) + Math.pow(target.y - me.y, 2));
var timeout = 0;
if (distance < 0) distance * -1;
while (distance > 5) {
if (timeout > 40) {
wowjs.wowLog("Pull timed out, cancelling fight");
wowjs.wowAbortCurFight = true;
return false;
}
me.wowSleep(100);
timeout++;
distance = Math.sqrt(Math.pow(target.x - me.x, 2) + Math.pow(target.y - me.y, 2));
if (distance < 0) distance * -1;
}
wowjs.wowLog("Mob is now in melee range, starting the fight.");
}
}
function checkflurry(){
var attacking = me.wowGetAttackingMobs();
var attackingnumber = 0;
var done = 0;
var i = 0;
while (done != 1) {
if (attacking[i] != null) {
attackingnumber++;
}else{
done = 1;
}
i++;
}
if (attackingnumber > 1) return true;
return false;
}
function checkApproachTarget(){
var target = me.target;
if (wowjs.fighterMode == 'BG') {
me.wowLog("BG mode, attacking everyone.");
return true;
}
if (target == null) {
wowjs.wowLog("Have no target, aborting.");
wowjs.wowAbortCurFight = true;
return false;
}
var tTarget = target.target;
if (tTarget == null || tTarget.wowIsSameObj(target))
return true;
if (tTarget.wowIsSameObj(me))
return true;
wowjs.wowLog("Target isn't targeting me, aborting.");
wowjs.wowAbortCurFight = true;
return false;
}
</script>