Register for your free account! | Forgot your password?

Go Back   elitepvpers > Coders Den > AutoIt
You last visited: Today at 09:47

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

Advertisement



Error Variable used .....

Discussion on Error Variable used ..... within the AutoIt forum part of the Coders Den category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Feb 2010
Posts: 134
Received Thanks: 107
Error Variable used .....

Hi,

PHP Code:
#include <NomadMemory.au3>         
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <ButtonConstants.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 GUICreate("Form1"625445193125)
$Input1 GUICtrlCreateInput("1"1128017721)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###






While True
    $nMsg 
GUIGetMsg()
    Switch 
$nMsg
        
Case $GUI_EVENT_CLOSE
            
Exit

    EndSwitch
    
$W_DATA2 _MEMORYPOINTERREAD($IV_ADDRESS$AH_HANDLE$AV_OFFSETHP$SV_TYPE4B)
If 
GUICtrlRead($Input1) = >2 then
        heilen
()
EndIf

WEnd


Func heilen
()
If 
$W_DATA2[1] < GUICtrlRead($Input1then
        Sleep
(5000)
        
ControlSend("LastChaos - Gamigo """"""{F3}")
EndIf
EndFunc
    

Global $IV_ADDRESS 106391E8
Global $IV_PID ProcessExists("Nksp.exe")
Global 
$AH_HANDLE _MEMORYOPEN($IV_PID)
Global 
$AV_OFFSETHP[2] = [0001076e8]
Global 
$SV_TYPE4B "dword"
Global $SV_TYPEF "float" 



Und zwar sollte das Sript wenn meine HP niedriger als der Wert der In der Inputbox ist F3 drücken.


Kann mir wer sagen was ich vergessen hab?
OldLucieN is offline  
Old 05/26/2010, 16:38   #2
 
Shadow992's Avatar
 
elite*gold: 77
Join Date: May 2008
Posts: 5,430
Received Thanks: 5,878
Quote:
Originally Posted by OldLucieN View Post
Hi,

PHP Code:
#include <NomadMemory.au3>         
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <ButtonConstants.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 GUICreate("Form1"625445193125)
$Input1 GUICtrlCreateInput("1"1128017721)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###






While True
    $nMsg 
GUIGetMsg()
    Switch 
$nMsg
        
Case $GUI_EVENT_CLOSE
            
Exit

    EndSwitch
    
$W_DATA2 _MEMORYPOINTERREAD($IV_ADDRESS$AH_HANDLE$AV_OFFSETHP$SV_TYPE4B)
If 
GUICtrlRead($Input1) = >2 then
        heilen
()
EndIf

WEnd


Func heilen
()
If 
$W_DATA2[1] < GUICtrlRead($Input1then
        Sleep
(5000)
        
ControlSend("LastChaos - Gamigo """"""{F3}")
EndIf
EndFunc
    

Global $IV_ADDRESS 106391E8
Global $IV_PID ProcessExists("Nksp.exe")
Global 
$AH_HANDLE _MEMORYOPEN($IV_PID)
Global 
$AV_OFFSETHP[2] = [0001076e8]
Global 
$SV_TYPE4B "dword"
Global $SV_TYPEF "float" 






Kann mir wer sagen was ich vergessen hab?
Ich stell da jetzt mal eine sehr gewagte Vermutung auf :
Es könnte eventuel sein , dass AutoIt die benutzte Variable wohl vor der Deklaration der Variable verwendet . Die Folge von dem ist normalerweise ein schönes kleines Fenster in dem irgendetwas wie "Variable used withouth being declared line 25" steht . Dieser Satz scheint wohl große Verwirrung unter der AutoIt-Elite zu stiften . Viele interpretieren diesen Satz falsch oder garnicht . Die Mehrzahl jedoch liest den Satz überhaupt nicht , wie das zustande kommt ist bisher unaufgeklärt , es gibt nur ein paar Spekulationen .

Spekulation 1 :
Der AutoIt Benutzer ist zu faul sich den fehler genauer durchzulesen .

Nummer 2 :
Der AutoIt Benutzer ist zu blöd um sich den Fehler genauer durchzulesen .

Nummer 3 :
Der AutoIt Benutzer sieht garkeinen Fehler und denkt , dass die schöne Box mit dem roten Kreis und dem weißen Kreuz eine Scherz ist .

Lösung :
Google benutzen :
Aber wie benutzt man Google ?
Ganz einfach , man nehme eine Suchmaschine , z.b. und gebe dort etwas ein . Google weiß auf alles eine Antwort man muss nur wissen nach was man suchen muss . So gibt es eine Vielzahl an Googlebenutzer , die mit dem Suchbegriff "Ey alter ich hab ein problem xD" zu keinem Ergebniss kommen und anschliesend Google verfluchen , weil es doch nicht alles weiß .

Damit man mal sieht , wie man richtig googelt :
Shadow992 is offline  
Thanks
1 User
Old 05/26/2010, 17:51   #3
 
elite*gold: 0
Join Date: Feb 2010
Posts: 134
Received Thanks: 107
Danke funktioniert jetzt.
OldLucieN is offline  
Old 05/26/2010, 17:52   #4
 
elite*gold: 0
Join Date: Nov 2009
Posts: 927
Received Thanks: 1,317
Probier's doch mal so rum:

PHP Code:
#include <NomadMemory.au3>         
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <ButtonConstants.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 GUICreate("Form1"625445193125)
$Input1 GUICtrlCreateInput("1"1128017721)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###



Global $IV_ADDRESS 106391E8
Global $IV_PID ProcessExists("Nksp.exe")
Global 
$AH_HANDLE _MEMORYOPEN($IV_PID)
Global 
$AV_OFFSETHP[2] = [0001076e8]
Global 
$SV_TYPE4B "dword"
Global $SV_TYPEF "float"  



While True
    $nMsg 
GUIGetMsg()
    Switch 
$nMsg
        
Case $GUI_EVENT_CLOSE
            
Exit

    EndSwitch
    
$W_DATA2 _MEMORYPOINTERREAD($IV_ADDRESS$AH_HANDLE$AV_OFFSETHP$SV_TYPE4B)
If 
GUICtrlRead($Input1) = >2 then
        heilen
()
EndIf

WEnd


Func heilen
()
If 
$W_DATA2[1] < GUICtrlRead($Input1then
        Sleep
(5000)
        
ControlSend("LastChaos - Gamigo """"""{F3}")
EndIf
EndFunc 
huberhans is offline  
Reply


Similar Threads Similar Threads
Problem error: Subscript used whit non-Array variable "
08/26/2010 - Last Chaos - 1 Replies
hey leute, seitdem mein laptop ein windows update gemacht hat funktioniert der ultra bot nicht. es dann kommt immer die fehlermeldung " error: Subscript used whit non-Array variable " vor diesem update ging der bot noch.
GUI-Input als Variable.
06/20/2010 - AutoIt - 8 Replies
Hey, ich habe mit KODA eine Inputbox erstellt, möchte nun aber dass ich das was ich in die Inputbox eintrage dann per 'OK'-Knopfdruck im schon vorher geöffnetem Notepad geschrieben wird. #include <GUIConstants.au3> #Region ### START Koda GUI section ### Form= $Form3 = GUICreate("Test", 116, 82, 303, 219) $Button1 = GUICtrlCreateButton("&OK", 8, 48, 99, 25) GUICtrlCreateInput("", 16, 16, 81, 21) GUISetState(@SW_SHOW)
'NewestCOServer.Game.Prof' is a 'type' but is used as a 'variable' Error
02/28/2010 - CO2 Private Server - 4 Replies
When I use this code I get an error: Prof(new Game.Prof() { ID = 410, Lvl = 12, Exp = 0 }); //Blade The error is: How can I fix this?
Variable und down/up befehl
09/23/2009 - AutoIt - 0 Replies
Hallo! Also ich habe folgendes Problem: Ich will meine variable ($taste1) und den "{down}" tastendruck ausführen aber wie krieg ich das hin also möchte das die variable taste1 runtergedrückt wird bis ich sie wieder mit "{up}" loslasse. Allerdings weis ich es bei up auch nicht Mein script sieht bisher so aus Send($taste1 "{down}") Thx schonmal in vorraus:confused::( ok habs jetzt nach langer zeit =) ich hab es einfach über eine if schleife gemacht Ok Funktioniert doch net hat keiner...
How do I add a variable
08/21/2009 - CO2 Private Server - 4 Replies
Couldn't find a guide when I searched. I want to make a variable so it will check how many times the player has already used unknown man. I know how to use the variable, but just don't know how to make it. Oh yea this is LOTF



All times are GMT +1. The time now is 09:47.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.

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