Auto ability in Abyss

Posts 1–4 of 4 · Page 1 of 1
Auto ability in Abyss
So this code is still incomplete, but I should have it working soon if I can get some help...

The idea is that the new pets are so OP that while running a dungeon lets say Abyss that you could almost pop your
abilility constantly. The code will check to see if you are in an abyss and that you are a pally, priest, or rogue before moving on.

If you meet these then the ability is spammed.

What I have so far:
Code:
; Check to see if you are in one of the desired Dungeons
getlex              QName(PackageNamespace(""), "map")
getproperty        QName(PackageNamespace(""), "name_")
setlocal
 
getlocal
pushstring          "Abyss of Demons"
ifeq                CLASS
 
jump                DONE
 
; Check to see what class you are using
CLASS:
getlex                QName(PackageNamespace(""), "map_")
getproperty        QName(PackageNamespace(""), "player_")
getproperty        QName(PackageNamespace(""), "objectType_")
pushint            784 ; Priest
ifeq              LOOP
 
getlex                QName(PackageNamespace(""), "map_")
getproperty        QName(PackageNamespace(""), "player_")
getproperty        QName(PackageNamespace(""), "objectType_")
pushint            768 ; Rogue
ifeq              LOOP
 
getlex                QName(PackageNamespace(""), "map_")
getproperty        QName(PackageNamespace(""), "player_")
getproperty        QName(PackageNamespace(""), "objectType_")
pushint            799 ; Paladin
ifeq              LOOP
 
jump              DONE
Inserted here com.company.assembleegameclient.objectslayer/update function, just before the returnvalue instruction at the end

Any help would be awesome! If we get this we can transition into auto potting as well.
Ok, first of all if you want to put it in the Player class then I don't really get why you always try to search for it in the memory instead of using getlocal0 (a.k.a. "*this"). It makes no sense at all, and probably it doesn't even work (note that I'm not an avm2/as3 expert). Since Player is a child of GameObject (and BasicObject), it has both map_ and objectType_ fields.

Another thing:
What is that setlocal, getlocal? setlocal and getlocal need an argument (a number that specifies the register where you want to store or load the data). On the top of it, there is no reason to put such instructions there, remove it.

The update method is already in a loop so you don't need to make another one in it and stop the game from working. It should simply look like this:
check for map and class
if matches jump to autouse
[else] jump to end
autouse:
[other checks like cooldown, mana, hp, etc]
call player's useAltWeapon method
end:

So you need to call the useAltWeapon with the mouse coordinates (map has mouseX and mouseY fields) and a constant which is 1 if I remember correctly.

Autopot is a lot easier, since you only need to check the hp, and use a hp pot if necessary (you can find out how in game/_-hw under the useHealthPotion part. optionally you can loop through the inv slots looking for hp pots and call the useItem(slotid) method)
use a proxy and let it keep track of your mana and have it send USE_ITEM packets ...
Quote Originally Posted by eth0nic View Post
use a proxy and let it keep track of your mana and have it send USE_ITEM packets ...
Your answer to everything.
I am pretty experienced with coding, but I wouldn't even know where to begin to make a proxy. I only know how to play with packets in real time

---------- Post added at 10:50 AM ---------- Previous post was at 10:45 AM ----------

Quote Originally Posted by DatCoder View Post
Ok, first of all if you want to put it in the Player class then I don't really get why you always try to search for it in the memory instead of using getlocal0 (a.k.a. "*this"). It makes no sense at all, and probably it doesn't even work (note that I'm not an avm2/as3 expert). Since Player is a child of GameObject (and BasicObject), it has both map_ and objectType_ fields.

Another thing:
What is that setlocal, getlocal? setlocal and getlocal need an argument (a number that specifies the register where you want to store or load the data). On the top of it, there is no reason to put such instructions there, remove it.

The update method is already in a loop so you don't need to make another one in it and stop the game from working. It should simply look like this:
check for map and class
if matches jump to autouse
[else] jump to end
autouse:
[other checks like cooldown, mana, hp, etc]
call player's useAltWeapon method
end:

So you need to call the useAltWeapon with the mouse coordinates (map has mouseX and mouseY fields) and a constant which is 1 if I remember correctly.

Autopot is a lot easier, since you only need to check the hp, and use a hp pot if necessary (you can find out how in game/_-hw under the useHealthPotion part. optionally you can loop through the inv slots looking for hp pots and call the useItem(slotid) method)
Thanks for your help as usual. I was basing my code off of an old script from nilly for 123.5.1 and she serched in the memory like that so I figured I would give it a shot.. So thats why I did that.

And I didn't know what I was going to set the local variables to yet so I just left them blank. I am aware they need a number lol. Thanks for the UseAltWeapon tip.

And my next goal after this is autopot
Posts 1–4 of 4 · Page 1 of 1

Post a Reply

Similar Threads

Tags for this Thread

None

Talk with us