Results 1 to 10 of 321

Thread: OK to ASK FOR HELP HERE!

Threaded View

  1. #21
    ©®™ Ralle1976's Avatar
    Join Date
    Jul 2012
    Location
    Ohmden
    Posts
    399

    kann man machen ^^

    Code:
    
    
    DerMoench hat es schon auf den Punkt gebracht ....
    aber der Vollständigkeit halber gebe ich auch mein Senf dazu ;) 
    
    
    
    Func WhatEverYouWanaDo()
    Local $TargetID = GetIfTargetIsPoisoned()
    ; when i rember well the UseSkillEx use a few checks inside and works with return State True/False 
    If IsRecharged($PoisonSkill) And UseSkillEx($PoisonSkill, $TargetID) Then Return True
    Return False
    EndFunc
    
    
    ;Example if your UseSkillEx() is equal to my one 
    IF Not WhatEverYouWanaDo() Then ContinueLoop 
    ; just an example there can also used some else instead of ContinueLoop 
    ; as long it is helpfull inside your Func Action
    ; idk if you understand and idk how your fight Func designed or however you will named it what you do
    ; but try to understand what you do and btw
    ; gwa2 is really easy to use... but think evertime about that it taxi your system 
    ; so break evertime your head over your func if you do clever and smart 
    
    
    Func GetIfTargetIsPoisoned()
    	
    	Local $lMe = GetAgentByID(-2)
    	Local $lAgentArray = GetAgentArray(0xDB)
    	For $i = 1 To $lAgentArray[0]
    		
    		If DllStructGetData($lAgentArray[$i], "HP") <= 0 Then ContinueLoop
    		If DllStructGetData($lAgentArray[$i], "Allegiance") <> 0x3 Then ContinueLoop
    
    		;if you not change position than this works else you have to take your struct everytime again in the Loop 
    		;=> $lMe = GetAgentByID(-2)
    		If GetDistance($lMe, $lAgentArray[$i]) > 250 Then ContinueLoop
    
    		If Not GetIsPoisoned($lAgentArray[$i]) Then Return DllStructGetData($lAgentArray[$i], "ID")
    
    	Next
    	Return 0
    EndFunc
    
    
    Last edited by Ralle1976; 01-09-2018 at 10:59 PM.

Posting Permissions

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