Page 30 of 32 FirstFirst ... 202829303132 LastLast
Results 291 to 300 of 318

Thread: OK to ASK FOR HELP HERE!

  1. #291
    Junior Member
    Join Date
    Jan 2017
    Posts
    19
    appoligies static but i still dont understand, is the problem with the script or gwa2? also if you have time could you talk me through it on skype plz?

  2. #292
    Junior Member
    Join Date
    Sep 2016
    Posts
    20
    Hi.
    I'm currently working on a bot to auto craft consets. I'm trying to find what function that works on the conset crafters in embark beach.
    i've been trying

    Buyitem(1, 1, 250)
    Traderbuy()

    none of those works and cannot seem to find any other buyitems functions in gwa...
    appreciate help

  3. #293
    Retired savsuds's Avatar
    Join Date
    Apr 2013
    Location
    'Murica
    Posts
    1,245
    Quote Originally Posted by znorkarn1337 View Post
    Hi.
    I'm currently working on a bot to auto craft consets. I'm trying to find what function that works on the conset crafters in embark beach.
    i've been trying

    Buyitem(1, 1, 250)
    Traderbuy()

    none of those works and cannot seem to find any other buyitems functions in gwa...
    appreciate help
    That is because those functions got placed inside gwApi by Testytest.
    Last edited by savsuds; 10-24-2017 at 12:45 AM.

  4. #294
    none in the original gwa2 but you can add it yourself, gwapi and gwaX have the functionality needed

  5. #295
    done ty all
    Last edited by rusco95; 11-25-2017 at 09:37 AM.

  6. #296
    Senior Member
    Join Date
    Feb 2016
    Posts
    167
    Hello, I am having trouble with a simple function that computes distance. I feel like I am either going about it wrong or have just been looking at it to long and now I am missing something simple. I just need the function to keep trying to get to a position until it reaches that position.

    Code:
    Func Blocked()  
    	 If GetMapLoading() == 2 Then Disconnected()
    		$Me = GetAgentByID(-2)
    		$COORDS_X = DllStructGetData($ME, "X")
    		$COORDS_Y = DllStructGetData($ME, "Y")
    		
    	    Do
    		  Sleep(200)
    		  MoveTo(-5488, 12655)		
    	    Until ComputeDistance(-5488, 12655, $COORDS_X, $COORDS_Y) < 80
     EndFunc

  7. #297
    youll need to be calling the $Me COORDS_X COORDS_Y shit in the loop because gwa2 is lame like that, have to constantly be refreshing your data

  8. #298
    Senior Member
    Join Date
    Feb 2016
    Posts
    167
    Quote Originally Posted by 4D 1 View Post
    youll need to be calling the $Me COORDS_X COORDS_Y shit in the loop because gwa2 is lame like that, have to constantly be refreshing your data
    Right on, thanks 4D1. I will experiment with it and see how it runs. Also, thanks Ralle for providing the more complex and effective solution.

  9. #299
    Junior Member sushitech's Avatar
    Join Date
    Nov 2015
    Location
    Germany
    Posts
    2
    hello!
    I have multiple targets and i want to use my aoe poison skill only if the targets isn't poisoned.

    Func Rotation
    If IsRecharged($PoisonSkill) And GetIfTargetIsPoisoned() > 1 Then
    UseSkillEx($PoisonSkill)
    EndIf
    EndFunc

    Func GetIfTargetIsPoisoned()
    Local $lMe = GetAgentByID(-2)
    Local $lAgentArray = GetAgentArray(0xDB)
    For $i = 1 To $lAgentArray[0]
    If DllStructGetData($lAgentArray[$i], "Allegiance") <> 0x3 Then ContinueLoop
    If DllStructGetData($lAgentArray[$i], "HP") <= 0 Then ContinueLoop
    If GetDistance($lMe, $lAgentArray[$i]) > 250 Then ContinueLoop
    If GetIsPoisoned($lAgentArray[$i]) Then ContinueLoop
    Return DllStructGetData($lAgentArray[$i], "ID")
    Next
    EndFunc

    Is that correct ?
    Last edited by sushitech; 01-09-2018 at 08:54 PM. Reason: lol quote

  10. #300
    Der Name der Funktion "GetIfTargetIsPoisoned()" ist etwas falsch gewählt, da Dir die Funktion den ersten feindlichen Agent returned,
    der nicht vergiftet ist.

    Davon ab wird
    Code:
    Func Rotation
    If IsRecharged($PoisonSkill) And GetIfTargetIsPoisoned() > 1 Then
    UseSkillEx($PoisonSkill)
    EndIf
    EndFunc
    so nicht funktionieren.

    Code:
    Func Rotation()                            ; schon wieder ein merkwürdiger Name ^^
         Local $Unpoisened_Target = GetIfTargetIsPoisoned()
         If IsRecharged(PoisonSkill) And $Unpoisened_Target > 0 Then UseSkillEx($PoisonSkill, $Unpoisened_Target)
    EndFunc
    Am Ende Deiner GetIfTargetIsPoisoned() (also vor EndFunc noch ein
    Code:
    return false
    Quasi als Error, wenn er keinen Agent gefunden hat der alle Kriterien erfüllt.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •