Register for your free account! | Forgot your password?

You last visited: Today at 20:17

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



GW Working Bots 2020

Discussion on GW Working Bots 2020 within the GW Exploits, Hacks, Bots, Tools & Macros forum part of the Guild Wars category.

Reply
 
Old 05/03/2021, 22:18   #1876
 
elite*gold: 0
Join Date: Apr 2018
Posts: 49
Received Thanks: 17
If i'm not wrong that func returns an array, maybe you are making a wrong use of the values?
OneStrangeGuy is offline  
Old 05/04/2021, 13:18   #1877
 
elite*gold: 0
Join Date: Jan 2019
Posts: 53
Received Thanks: 23
Quote:
Originally Posted by ottam View Post
Is there something wrong with this function?

It is crashing the game.

Func GetNearestEnemyToAgent($aAgent = -2)
Local $lNearestAgent, $lNearestDistance = 100000000
Local $lDistance
Local $lAgentArray = GetAgentArray(0xDB)

If Not IsDllStruct($aAgent) Then $aAgent = GetAgentByID($aAgent)

Local $lID = DllStructGetData($aAgent, 'ID')

For $i = 1 To $lAgentArray[0]
$lDistance = (DllStructGetData($aAgent, 'X') - DllStructGetData($lAgentArray[$i], 'X')) ^ 2 + (DllStructGetData($aAgent, 'Y') - DllStructGetData($lAgentArray[$i], 'Y')) ^ 2
If DllStructGetData($lAgentArray[$i], 'Allegiance') <> 3 Then ContinueLoop
If DllStructGetData($lAgentArray[$i], 'HP') <= 0 Then ContinueLoop
If BitAND(DllStructGetData($lAgentArray[$i], 'Effects'), 0x0010) > 0 Then ContinueLoop

$lDistance = (DllStructGetData($aAgent, 'X') - DllStructGetData($lAgentArray[$i], 'X')) ^ 2 + (DllStructGetData($aAgent, 'Y') - DllStructGetData($lAgentArray[$i], 'Y')) ^ 2
If $lDistance < $lNearestDistance Then
If DllStructGetData($lAgentArray[$i], 'ID') == $lID Then ContinueLoop
$lNearestAgent = $lAgentArray[$i]
$lNearestDistance = $lDistance
EndIf
Next

SetExtended(Sqrt($lNearestDistance))
Return $lNearestAgent
EndFunc ;==>GetNearestEnemyToAgent
Why are you so certain that this function crashes the game? Maybe one of the functions that calls this one is trying to perform illegal actions, hence the game crashing.
What errors do you get, which part of your code actually crashes the game?
FriendlyFarmer is offline  
Old 05/05/2021, 16:13   #1878
 
elite*gold: 0
Join Date: Dec 2014
Posts: 18
Received Thanks: 2
Quote:
Originally Posted by ottam View Post
Is there something wrong with this function?

It is crashing the game.

Func GetNearestEnemyToAgent($aAgent = -2)
Local $lNearestAgent, $lNearestDistance = 100000000
Local $lDistance
Local $lAgentArray = GetAgentArray(0xDB)

If Not IsDllStruct($aAgent) Then $aAgent = GetAgentByID($aAgent)

Local $lID = DllStructGetData($aAgent, 'ID')

For $i = 1 To $lAgentArray[0]
$lDistance = (DllStructGetData($aAgent, 'X') - DllStructGetData($lAgentArray[$i], 'X')) ^ 2 + (DllStructGetData($aAgent, 'Y') - DllStructGetData($lAgentArray[$i], 'Y')) ^ 2
If DllStructGetData($lAgentArray[$i], 'Allegiance') <> 3 Then ContinueLoop
If DllStructGetData($lAgentArray[$i], 'HP') <= 0 Then ContinueLoop
If BitAND(DllStructGetData($lAgentArray[$i], 'Effects'), 0x0010) > 0 Then ContinueLoop

$lDistance = (DllStructGetData($aAgent, 'X') - DllStructGetData($lAgentArray[$i], 'X')) ^ 2 + (DllStructGetData($aAgent, 'Y') - DllStructGetData($lAgentArray[$i], 'Y')) ^ 2
If $lDistance < $lNearestDistance Then
If DllStructGetData($lAgentArray[$i], 'ID') == $lID Then ContinueLoop
$lNearestAgent = $lAgentArray[$i]
$lNearestDistance = $lDistance
EndIf
Next

SetExtended(Sqrt($lNearestDistance))
Return $lNearestAgent
EndFunc ;==>GetNearestEnemyToAgent
If i am not mistaken, this function and toolbox don't go well together and cause a crash.
YueNiu is offline  
Old 05/06/2021, 06:48   #1879
 
elite*gold: 0
Join Date: Dec 2013
Posts: 53
Received Thanks: 10
Quote:
Originally Posted by list comprehension View Post
I added a write up on pattern scanning updates as previously stated:
I tried following your guide to find patterns to update the GWA2 for certain functions to work but have been unsuccessful. I even used the exact pattern you showed as an example for ScanTraderFunction and it just keeps erroring and closing the GW client. I even updated some of the patterns that yoshikawa helped me out with but that errors out my guild wars client as well.

Has anyone else had any luck updating this or does someone have a working, updated GWA2 already?
epvp_dragon is offline  
Old 05/07/2021, 21:01   #1880
 
elite*gold: 0
Join Date: Apr 2021
Posts: 6
Received Thanks: 10
anyone can help me with a func that detect if all party is dead?
The Sav3r is offline  
Old 05/07/2021, 22:56   #1881
 
elite*gold: 0
Join Date: May 2010
Posts: 58
Received Thanks: 31
Moin Leute...

Da mein Englisch eine mittelschwere Katastrophe ist, bin ich leider gezwungen hier mal auf deutsch zu fragen.

Was ich geschnallt habe:
- alte Bots funktionieren nicht mehr, da ein Update alles kaputt gemacht hat
- man Braucht die neue GWA2.au3
- man Braucht die GWA2_Headers.au3
- man muss in die alten "Scripts" #include GWA2_Headers.au3

Was ich überhaupt nicht gerafft habe:

- die Option "Func PickUpLoot" und weshalb sie nicht mehr geht...
- welshalb mein Sunspearbot abschmiert, sobald der Wurm benutzt wird etc...

Vieleicht hat ja jemand mal Zeit und Lust mir dem Kram etwas zu erklären und näher zu bringen.

LG
CookiesCream is offline  
Old 05/08/2021, 00:56   #1882
 
elite*gold: 0
Join Date: Apr 2018
Posts: 49
Received Thanks: 17
Quote:
Originally Posted by The Sav3r View Post
anyone can help me with a func that detect if all party is dead?
Modify this Func to your needs:

Code:
Func CheckPartyDead()
	$DeadParty = 0
	For $i =1 to GetHeroCount()
		If GetIsDead(GetHeroID($i)) = True Then
			$DeadParty +=1
		EndIf
		If $DeadParty >= 6 Then
			$DeadOnTheRun = 1
			CurrentAction("We Wipe, going back oupost to save time")
		EndIf
	Next
EndFunc
OneStrangeGuy is offline  
Old 05/08/2021, 01:13   #1883
 
elite*gold: 0
Join Date: Feb 2014
Posts: 20
Received Thanks: 0
Hi Guys,
I always get this message when I start the new GWA2.
"Line 1505 (File" C: \ .... kilroy \ GWA2.au3 "):

Return SendPacket (0x18, $ HEADER_MAP_TRAVEL, $ aMapID,
$ aRegion, $ aDistrict, $ aLanguage, False)
Return SendPacket (0x18, ^ ERROR

Error: Variable used without beeing declared "

I tried to declare the variable, but the game crashes. The command looks like this "Global Const $ HEADER_MAP_TRAVEL = 0x18"

What did I do wrong?
monsterzone93 is offline  
Old 05/08/2021, 01:40   #1884
 
elite*gold: 0
Join Date: May 2014
Posts: 269
Received Thanks: 328
Delete the Space between $ and H.
DerMoench14 is offline  
Old 05/08/2021, 12:03   #1885
 
elite*gold: 0
Join Date: Oct 2009
Posts: 25
Received Thanks: 8
Quote:
Originally Posted by CookiesCream View Post
Moin Leute...

Da mein Englisch eine mittelschwere Katastrophe ist, bin ich leider gezwungen hier mal auf deutsch zu fragen.

Was ich geschnallt habe:
- alte Bots funktionieren nicht mehr, da ein Update alles kaputt gemacht hat
- man Braucht die neue GWA2.au3
- man Braucht die GWA2_Headers.au3
- man muss in die alten "Scripts" #include GWA2_Headers.au3

Was ich überhaupt nicht gerafft habe:

- die Option "Func PickUpLoot" und weshalb sie nicht mehr geht...
- welshalb mein Sunspearbot abschmiert, sobald der Wurm benutzt wird etc...

Vieleicht hat ja jemand mal Zeit und Lust mir dem Kram etwas zu erklären und näher zu bringen.

LG
die Func PickUpLoot funktioniert eigentlich, was nicht klappt ohne dirtyfix ist das verkaufen.

Das der skill nicht funkt, kann natürlich an den headers liegen.
ich habe imo auch das problem, dass bei annahme von Questen GW abschmiert ohne error - das erschwärt die fehler suche ...

hier mal meine func:

PHP Code:
Func PickUpLoot()
    
Local $lMe
    Local $lBlockedTimer
    Local $lBlockedCount 
0
    Local $lItemExists 
True

    
For $i 1 To GetMaxAgents()
        
$lAgent GetAgentByID($i)
        If (
CountFreeSlots()=0Then Return False
        
If Not (GetIsMovable($lAgent)) Then ContinueLoop
        
If Not (GetCanPickUp($lAgent)) Then ContinueLoop
        $lItem 
GetItemByAgentID($i)
        If (
CanPickUp2($lItem)) Then ;hier mal prüfen ob die Function vorhanden istansonsten anpassen
            
Do
                If (
GetDistance($lItem) > 150Then Move(DllStructGetData($lItem'X'), DllStructGetData($lItem'Y'))
                
PickUpItem($lItem)
                
Sleep(GetPing())
                Do
                    If (
GetIsDead(-2)) Then Return False
                    Sleep
(100)
                    
$lMe GetAgentByID(-2)
                
Until ((DllStructGetData($lMe'MoveX') == 0) AND (DllStructGetData($lMe'MoveY') == 0))
                
$lBlockedTimer TimerInit()
                Do
                    If (
GetIsDead(-2)) Then Return False
                    Sleep
(3)
                    
$lItemExists IsDllStruct(GetAgentByID($i))
                
Until Not ($lItemExists) OR (TimerDiff($lBlockedTimer) > Random(500075001))
                If 
$lItemExists Then $lBlockedCount += 1
            Until Not $lItemExists 
OR $lBlockedCount 5
        
EndIf
    
Next
EndFunc   
;==>PickUpLoot 
zer0.de is offline  
Old 05/09/2021, 04:34   #1886
 
elite*gold: 0
Join Date: May 2020
Posts: 10
Received Thanks: 0
I'm writing a bot for Auto ST player, where while in combat, I want to use the Displacement, Shelter ... Question, how can I check if I have a certain buff so I don't spam it if the skill is available? Is there a function to check buff on another player/hero also for weapon spells?
markgw3 is offline  
Old 05/09/2021, 12:04   #1887
 
elite*gold: 0
Join Date: Apr 2018
Posts: 49
Received Thanks: 17
Quote:
Originally Posted by markgw3 View Post
I'm writing a bot for Auto ST player, where while in combat, I want to use the Displacement, Shelter ... Question, how can I check if I have a certain buff so I don't spam it if the skill is available? Is there a function to check buff on another player/hero also for weapon spells?
Your GWA2 should have the GetEffect Func, use something like this to see if your target has a specific buff.

Code:
Func HasEffect($aEffectSkillID)
   If DllStructGetData(GetEffect($aEffectSkillID), "SkillID") == 0 Then
	  Return False
   Else
	  Return True
   EndIf
EndFunc
OneStrangeGuy is offline  
Thanks
1 User
Old 05/09/2021, 12:12   #1888
 
elite*gold: 0
Join Date: Jan 2010
Posts: 23
Received Thanks: 8
Is there a way to post all functional bots in one thread? or maybe start a new topic with bots 2021?
Kn!ckl3s is offline  
Thanks
1 User
Old 05/09/2021, 17:36   #1889
 
elite*gold: 0
Join Date: May 2019
Posts: 11
Received Thanks: 0
Hi guys,

I'm having trouble fixing the Follower Bot. I managed to fix the following fonction, but I face difficulties with the Attack fonction. The second account only cast their first spell of the skillbar.

PHP Code:
Func Attack($x$s "enemies")
    
local $TimerToGetOut TimerInit()
    Do
        
$useSkill = -1
        $target 
GetNearestEnemyToAgent(-2)
        
$distance GetDistance($target, -2)
        If 
DllStructGetData($target'ID') <> AND $distance $x Then
            ChangeTarget
($target)
            
Sleep(150)
            
CallTarget($target)
            
Sleep(150)
            
Attack($target)
            
Sleep(150)
        ElseIf 
DllStructGetData($target'ID') = OR $distance $x Then
            exitloop
        
EndIf

        For 
$i 0 To 8

            $targetHP 
DllStructGetData(GetCurrentTarget(),'HP')
            if 
$targetHP 0 then ExitLoop

            $distance 
GetDistance($target, -2)
            if 
$distance $x then ExitLoop

            $TargetAllegiance 
DllStructGetData(GetCurrentTarget(),'Allegiance')
            if 
$TargetAllegiance 0x1 OR $TargetAllegiance 0x4 OR $TargetAllegiance 0x5 OR $TargetAllegiance 0x6 Then ExitLoop

            $TargetIsDead 
DllStructGetData(GetCurrentTarget(), 'Effects')
            If 
$TargetIsDead 0x0010 Then ExitLoop

            $TargetItem 
DllStructGetData(GetCurrentTarget(),'Type')
            if 
$TargetItem 0x400 then ExitLoop

            $energy 
GetEnergy(-2)
            
$recharge DllStructGetData(GetSkillBar(), "Recharge" $i+1)
            
$adrenaline DllStructGetData(GetSkillBar(), "Adrenaline" $i+1)


Local $Energy StringReplace(StringReplace(StringReplace(StringMid(DllStructGetData($useskill'Unknown4'), 61), 'C''25'), 'B''15'), 'A''10')
            If 
$recharge 0 Then
                $useSkill 
$i 1
                $variabletosort 
0
                UseSkill
($useSkill$target)
                
Sleep(200)
            EndIf
            
$target GetNearestEnemyToAgent(-2)
            
Attack($target)
            
Sleep(150)
            if 
$i 8 then $i = -change -1
        Next

        $TargetAllegiance 
DllStructGetData(GetCurrentTarget(),'Allegiance')
        
$TargetIsDead DllStructGetData(GetCurrentTarget(), 'Effects')
        
$targetHP DllStructGetData(GetCurrentTarget(),'HP')
        
$TargetItem DllStructGetData(GetCurrentTarget(),'Type')
    
Until DllStructGetData($target'ID') = OR $distance $x OR $TargetAllegiance 0x1 OR $TargetAllegiance 0x4 OR $TargetAllegiance 0x5 OR $TargetAllegiance 0x6 OR $TargetIsDead 0x0010 OR $targetHP OR $TargetItem 0x400 OR TimerDiff($TimerToGetOut) > 240000
EndFunc 
Btw, I'm a beginner with code, so don't judge me if you think the changes I made are not optimized
Paki29 is offline  
Old 05/10/2021, 08:04   #1890
 
elite*gold: 0
Join Date: May 2020
Posts: 10
Received Thanks: 0
Quote:
Originally Posted by OneStrangeGuy View Post
Your GWA2 should have the GetEffect Func, use something like this to see if your target has a specific buff.

Code:
Func HasEffect($aEffectSkillID)
   If DllStructGetData(GetEffect($aEffectSkillID), "SkillID") == 0 Then
	  Return False
   Else
	  Return True
   EndIf
EndFunc
Got it, I think my GetEffect is busted. It returns False when the spirit is alive, but for Shelter, it just keeps spamming it. Do you call TargetSelf() before using this? It seems GetEffect targets self already since $aHeroNumber = 0, which I am assuming the player itself. I think my GWA2 might be super outdated, would you mind sharing me yours I can probably figure out what the problem on my end. From what I read, it's suppose to return to me an array or struct, but what to do with that array lol I have no idea. My console keeps saying Shelter doesn't exist, but Displacement and Union do and doesn't get casted, Shelter on the other hand keeps getting spammed. I'm very close though! Appreciate all your help

I've only been writing my own bots for a little bit so I'm getting used to fixing certain functions.
markgw3 is offline  
Reply


Similar Threads Similar Threads
[WTT] UPlay Anno 2020 Complete Key gegen Anno 1404/Anno 2020 Complete STEAM
08/12/2015 - Steam Trading - 0 Replies
Want to Trade UPlay Anno 2020 Complete Key gegen Anno 1404 oder Anno 2020 Complete STEAM only with Middleman



All times are GMT +1. The time now is 20:18.


Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2025 elitepvpers All Rights Reserved.