Thank you it is working now! Holy shit i went full retard mode!Quote:
Seem found error here; replace DonateFaction(1) by DonateFaction(l) (k for kurzick l for luxon and not 1 the number)
Thank you it is working now! Holy shit i went full retard mode!Quote:
Seem found error here; replace DonateFaction(1) by DonateFaction(l) (k for kurzick l for luxon and not 1 the number)
Quote:
Enum $SKILL_Contagion = 1, _
$SKILL_DarkAura, _
$SKILL_DeathNova, _
$SKILL_PutridBile, _
$SKILL_ShadowWalk, _
$SKILL_SignetOfAgony, _
$SKILL_TouchOfAgony, _
$SKILL_Dash
Func TradeWinExist() Local $lOffset = [0, 24, 88, 0] Return MemoryreadPtr($mBasePointer, $lOffset)[1] EndFunc ;==>Trade Window Exist Func TradeOfferItemExist() Local $lOffset = [0, 24, 88, 40, 0] Return MemoryReadPtr($mBasePointer, $lOffset)[1] EndFunc ;==>Trade Offer Items Exist Func TradeOfferMoneyExist() Local $lOffset = [0, 24, 88, 36] Return MemoryReadPtr($mBasePointer, $lOffset)[1] EndFunc ;==>Trade Offer Money Exist
Global $BotRunning = False
#Region GUI
Global Const $mainGui = GUICreate("Mantid", 350, 175)
GUISetOnEvent($GUI_EVENT_CLOSE, "_exit")
Global $Input
If $doLoadLoggedChars Then
$Input = GUICtrlCreateCombo("", 8, 8, 129, 21)
GUICtrlSetData(-1, GetLoggedCharNames())
Else
$Input = GUICtrlCreateInput("character name", 8, 8, 129, 21)
EndIf
GUICtrlCreateLabel("Successful Run:", 8, 50, 70, 17)
Global Const $RunsLabel = GUICtrlCreateLabel($RunCount, 80, 50, 50, 17)
GUICtrlCreateLabel("Failed Run:", 8, 65, 70, 17)
Global Const $FailsLabel = GUICtrlCreateLabel($FailCount, 80, 65, 50, 17)
GUICtrlCreateLabel("Shield:", 8, 80, 70, 17)
Global Const $DropsCount = GUICtrlCreateLabel("0", 80, 80, 50, 17)
GUICtrlCreateLabel("Sword:", 8, 95, 70, 17)
Global Const $DropsCount2 = GUICtrlCreateLabel("0", 80, 95, 50, 17)
Global Const $Checkbox = GUICtrlCreateCheckbox("Stop Rendering", 8, 125, 129, 17)
GUICtrlSetState(-1, $GUI_DISABLE)
GUICtrlSetOnEvent(-1, "ToggleRendering")
Global Const $Button = GUICtrlCreateButton("Start", 8, 145, 131, 25)
GUICtrlSetOnEvent($Button, "GuiButtonHandler")
Global Const $StatusLabel = GUICtrlCreateLabel("", 8, 190, 125, 17)
Global $GLOGBOX = GUICtrlCreateEdit("", 140, 8, 200, 165, BitOR($ES_AUTOVSCROLL, $ES_AUTOHSCROLL, $ES_WANTRETURN, $WS_VSCROLL))
GUICtrlSetColor($GLOGBOX, 65280)
GUICtrlSetBkColor($GLOGBOX, 0)
GUISetState(@SW_SHOW)
Func GuiButtonHandler()
If $BotRunning Then
GUICtrlSetData($Button, "Pauses after this round")
GUICtrlSetState($Button, $GUI_DISABLE)
$BotRunning = False
ElseIf $BotInitialized Then
GUICtrlSetData($Button, "Pause")
$BotRunning = True
Else
Out("Starting")
Local $CharName = GUICtrlRead($Input)
If $CharName=="" Then
If Initialize(ProcessExists("gw.exe"), True, True, True) = False Then
MsgBox(0, "Error", "GW is not open")
Exit
EndIf
WinSetTitle($mainGui, "", "Celestial Weapons Farm Bot_" & GetCharname())
Else
If Initialize($CharName, True, True, True) = False Then ;
MsgBox(0, "Error", "Cannot find character: '"&$CharName&"'")
Exit
EndIf
WinSetTitle($mainGui, "", "Celestial Weapons Farm Bot_" & $CharName)
EndIf
GUICtrlSetState($Checkbox, $GUI_ENABLE)
GUICtrlSetData($Button, "Pause")
$BotRunning = True
$BotInitialized = True
EndIf
EndFunc
Neighter the GStoC-Packet nor the Position of the Trade-Window are the right place you're looking for.Quote:
Does Somebody have the right offsets for me for these functions? How can i find Offsets? I am using the c++ developer tool.
I did some google search and came out on cheat engine everytime. Is that usable for this game to find out the offsets?
For example: Packet 5 would be the trade window i think.Code:Func TradeWinExist() Local $lOffset = [0, 24, 88, 0] Return MemoryreadPtr($mBasePointer, $lOffset)[1] EndFunc ;==>Trade Window Exist Func TradeOfferItemExist() Local $lOffset = [0, 24, 88, 40, 0] Return MemoryReadPtr($mBasePointer, $lOffset)[1] EndFunc ;==>Trade Offer Items Exist Func TradeOfferMoneyExist() Local $lOffset = [0, 24, 88, 36] Return MemoryReadPtr($mBasePointer, $lOffset)[1] EndFunc ;==>Trade Offer Money Exist
-- PACKET: P005
<GStoC> Size: 0x8 Header: 0x5
05 00 00 00 5D 00 00 00
---------------------------------
0x00 Header => 5
0x04 DWORD => 93 float => 0.000000
---------------------------------
Are these the offsets? I found this C++ Developer Tools -> GW-Config. I'm afraid this is for ingame settings and not to identify if a window exists.
Hmmm edit... the image don't show.
[IMG][Only registered and activated users can see links. Click Here To Register...][/IMG]
Anyways! Help would be much appreciated! Thanks in advance!
Func TradeWinExist() Local $lOffset[4] = [0, 0x18, 0x58, 0] Local $TradePtr = MemoryReadPtr($mBasePointer, $lOffset) Return MemoryRead($TradePtr[0], 'long') > 0 EndFunc ;==>Trade Window Exist Func TradeOfferItemExist() Local $lOffset[4] = [0, 0x18, 0x58, 0] Local $TradePtr = MemoryReadPtr($mBasePointer, $lOffset) Return MemoryRead($TradePtr[0] + 0x28, 'ptr') > 0 EndFunc ;==>Trade Offer Items Exist Func TradeOfferMoneyExist() Local $lOffset[4] = [0, 0x18, 0x58, 0] Local $TradePtr = MemoryReadPtr($mBasePointer, $lOffset) Return MemoryRead($TradePtr[0] + 0x24, 'ptr') > 0 EndFunc ;==>Trade Offer Money Exist
Have you setQuote:
Maybe i'm blind ;) but cannot find my error to have function "Pauses after this round" working
Code:Global $BotRunning = FalseCode:#Region GUI Global Const $mainGui = GUICreate("Mantid", 350, 175) GUISetOnEvent($GUI_EVENT_CLOSE, "_exit") Global $Input If $doLoadLoggedChars Then $Input = GUICtrlCreateCombo("", 8, 8, 129, 21) GUICtrlSetData(-1, GetLoggedCharNames()) Else $Input = GUICtrlCreateInput("character name", 8, 8, 129, 21) EndIf GUICtrlCreateLabel("Successful Run:", 8, 50, 70, 17) Global Const $RunsLabel = GUICtrlCreateLabel($RunCount, 80, 50, 50, 17) GUICtrlCreateLabel("Failed Run:", 8, 65, 70, 17) Global Const $FailsLabel = GUICtrlCreateLabel($FailCount, 80, 65, 50, 17) GUICtrlCreateLabel("Shield:", 8, 80, 70, 17) Global Const $DropsCount = GUICtrlCreateLabel("0", 80, 80, 50, 17) GUICtrlCreateLabel("Sword:", 8, 95, 70, 17) Global Const $DropsCount2 = GUICtrlCreateLabel("0", 80, 95, 50, 17) Global Const $Checkbox = GUICtrlCreateCheckbox("Stop Rendering", 8, 125, 129, 17) GUICtrlSetState(-1, $GUI_DISABLE) GUICtrlSetOnEvent(-1, "ToggleRendering") Global Const $Button = GUICtrlCreateButton("Start", 8, 145, 131, 25) GUICtrlSetOnEvent($Button, "GuiButtonHandler") Global Const $StatusLabel = GUICtrlCreateLabel("", 8, 190, 125, 17) Global $GLOGBOX = GUICtrlCreateEdit("", 140, 8, 200, 165, BitOR($ES_AUTOVSCROLL, $ES_AUTOHSCROLL, $ES_WANTRETURN, $WS_VSCROLL)) GUICtrlSetColor($GLOGBOX, 65280) GUICtrlSetBkColor($GLOGBOX, 0) GUISetState(@SW_SHOW)If someone have an idea, welcome :DCode:Func GuiButtonHandler() If $BotRunning Then GUICtrlSetData($Button, "Pauses after this round") GUICtrlSetState($Button, $GUI_DISABLE) $BotRunning = False ElseIf $BotInitialized Then GUICtrlSetData($Button, "Pause") $BotRunning = True Else Out("Starting") Local $CharName = GUICtrlRead($Input) If $CharName=="" Then If Initialize(ProcessExists("gw.exe"), True, True, True) = False Then MsgBox(0, "Error", "GW is not open") Exit EndIf WinSetTitle($mainGui, "", "Celestial Weapons Farm Bot_" & GetCharname()) Else If Initialize($CharName, True, True, True) = False Then ; MsgBox(0, "Error", "Cannot find character: '"&$CharName&"'") Exit EndIf WinSetTitle($mainGui, "", "Celestial Weapons Farm Bot_" & $CharName) EndIf GUICtrlSetState($Checkbox, $GUI_ENABLE) GUICtrlSetData($Button, "Pause") $BotRunning = True $BotInitialized = True EndIf EndFunc
Opt("GUIOnEventMode", 1)
AUTOITSETOPTION("TrayIconDebug", 1)
Damn, thanks buddy.:mofo: But to learn from this where to look for it? What tools and how can i look for this myself?Quote:
Neighter the GStoC-Packet nor the Position of the Trade-Window are the right place you're looking for.
Still works for me ...Code:Func TradeWinExist() Local $lOffset[4] = [0, 0x18, 0x58, 0] Local $TradePtr = MemoryReadPtr($mBasePointer, $lOffset) Return MemoryRead($TradePtr[0], 'long') > 0 EndFunc ;==>Trade Window Exist Func TradeOfferItemExist() Local $lOffset[4] = [0, 0x18, 0x58, 0] Local $TradePtr = MemoryReadPtr($mBasePointer, $lOffset) Return MemoryRead($TradePtr[0] + 0x28, 'ptr') > 0 EndFunc ;==>Trade Offer Items Exist Func TradeOfferMoneyExist() Local $lOffset[4] = [0, 0x18, 0x58, 0] Local $TradePtr = MemoryReadPtr($mBasePointer, $lOffset) Return MemoryRead($TradePtr[0] + 0x24, 'ptr') > 0 EndFunc ;==>Trade Offer Money Exist
:handsdown::handsdown: So cheatengine is used for that. I read somewhere that based on runtime the pointers would change and that cheat engine could not be used on guild wars but that didnt make any sense to me since $mBasepointer is a static pointer and besides that how can the game itself now where to point in memory. It's prolly a lot more complicated. Anyways. i can do some more research now in the right direction! Cheers!Quote:
Any Debugger you like will do ..
CE ist easy to use for beginner ...
i have rebuild all constants, GUIbutton handler and the GUI... All working fine now ;) Tks for the helpQuote:
Use
to help determine where your code pointer is...Code:AUTOITSETOPTION("TrayIconDebug", 1)
Also $botrunning should be False to initialize a pause... Your GUIbutton handler is corrupt... look at my blades FREE file to get the correct code for that pause after round method.