Well , i tried something too
And i get this "Warning : $open: possibly used before declaration.
Error : $open: undeclared global variable" at this line :
#RequireAdmin
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_Icon=D:\Program Files (x86)\AeriaGames\S4League\s4league_web.ico
#AutoIt3Wrapper_Outfile_x64=..\Trainer TestD.Exe
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <NoMadMemory.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Alex's Trainer", 347, 184, 449, 124)
$Checkbox1 = GUICtrlCreateCheckbox("Godmode", 136, 8, 97, 17)
$Checkbox2 = GUICtrlCreateCheckbox("Inf Ammo", 136, 40, 97, 17)
$Checkbox3 = GUICtrlCreateCheckbox("Inf Sp", 136, 72, 97, 17)
$Checkbox4 = GUICtrlCreateCheckbox("Conquest", 136, 104, 97, 17)
$Button1 = GUICtrlCreateButton("Exit", 136, 136, 75, 25)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
#Pid = ProcessExists("S4Client.exe")
#OPEN = _MemoryOpen ($Pid)
$InfSp = _MemoryScan(_MemoryOpen(ProcessExists("S4Client.ex e")),"D945F88BE55DC3CCCCCCCCCCCCCC558BEC51894D" )
$InfAmmo = _MemoryScan(_MemoryOpen(ProcessExists("S4Client.ex e")),"7605E9????????8B55E83B55087E0B8B45E8")
$Godmode = _MemoryScan(_MemoryOpen(ProcessExists("S4Client.ex e")),"7205E9????????8B4D908B118B4D908B4244FFD00FB6 C8")
$Conquest = _MemoryScan(_MemoryOpen(ProcessExists("S4Client.ex e")),"7514C745fC????????8D4D08E8????????E9???????? C745")
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $Button1
Exit
Case $Checkbox3
If GUICtrlRead($Checkbox3) = 3 Then
_memorywrite($InfSp,$open,"2348565979","Long")
Else
_memorywrite($InfSp,$open,"2348565977","Long")
EndIf
Case $Checkbox2
If GUICtrlRead($Checkbox2) = 2 Then
_memorywrite($InfAmmo,$open,"2833843572","Long")
Else
_memorywrite($InfAmmo,$open,"2833843573","Long")
EndIf
Case $Checkbox1
If GUICtrlRead($Checkbox1) = 1 Then
_memorywrite($Godmode,$open,"3488190608","Long")
Else
_memorywrite($Godmode,$open,"3488155002","Long")
EndIf
Case $Checkbox4
If GUICtrlRead($Checkbox4) = 4 Then
_memorywrite($Conquest,$open,"2348565970","Long")
Else
_memorywrite($Conquest,$open,"990136971","Long")
EndIf
EndSwitch
WEnd
Func _MemoryScan($ah_Handle, $pattern, $after = False, $iv_addrStart = 0x00000000, $iv_addrEnd = 0X0FFFFFFF, $step = 51200)
If Not IsArray($ah_Handle) Then
SetError(1)
Return -1
EndIf
$pattern = StringRegExpReplace($pattern, "[^0123456789ABCDEFabcdef.]", "")
If StringLen($pattern) = 0 Then
SetError(2)
Return -2
EndIf
For $addr = $iv_addrStart To $iv_addrEnd Step $step - (StringLen($pattern) / 2)
StringRegExp(_MemoryRead($addr, $ah_Handle, "byte[" & $step & "]"), $pattern, 1, 2)
If Not @error Then
If $after Then
Return StringFormat("0x%.8X", $addr + ((@extended - 2) / 2))
Else
Return StringFormat("0x%.8X", $addr + ((@extended - StringLen($pattern) - 2) / 2))
EndIf
EndIf
Next
Return -3
EndFunc ;==>_MemoryScan
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_Icon=D:\Program Files (x86)\AeriaGames\S4League\s4league_web.ico
#AutoIt3Wrapper_Outfile_x64=..\Trainer TestD.Exe
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <NoMadMemory.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Alex's Trainer", 347, 184, 449, 124)
$Checkbox1 = GUICtrlCreateCheckbox("Godmode", 136, 8, 97, 17)
$Checkbox2 = GUICtrlCreateCheckbox("Inf Ammo", 136, 40, 97, 17)
$Checkbox3 = GUICtrlCreateCheckbox("Inf Sp", 136, 72, 97, 17)
$Checkbox4 = GUICtrlCreateCheckbox("Conquest", 136, 104, 97, 17)
$Button1 = GUICtrlCreateButton("Exit", 136, 136, 75, 25)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
#Pid = ProcessExists("S4Client.exe")
#OPEN = _MemoryOpen ($Pid)
$InfSp = _MemoryScan(_MemoryOpen(ProcessExists("S4Client.ex e")),"D945F88BE55DC3CCCCCCCCCCCCCC558BEC51894D" )
$InfAmmo = _MemoryScan(_MemoryOpen(ProcessExists("S4Client.ex e")),"7605E9????????8B55E83B55087E0B8B45E8")
$Godmode = _MemoryScan(_MemoryOpen(ProcessExists("S4Client.ex e")),"7205E9????????8B4D908B118B4D908B4244FFD00FB6 C8")
$Conquest = _MemoryScan(_MemoryOpen(ProcessExists("S4Client.ex e")),"7514C745fC????????8D4D08E8????????E9???????? C745")
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $Button1
Exit
Case $Checkbox3
If GUICtrlRead($Checkbox3) = 3 Then
_memorywrite($InfSp,$open,"2348565979","Long")
Else
_memorywrite($InfSp,$open,"2348565977","Long")
EndIf
Case $Checkbox2
If GUICtrlRead($Checkbox2) = 2 Then
_memorywrite($InfAmmo,$open,"2833843572","Long")
Else
_memorywrite($InfAmmo,$open,"2833843573","Long")
EndIf
Case $Checkbox1
If GUICtrlRead($Checkbox1) = 1 Then
_memorywrite($Godmode,$open,"3488190608","Long")
Else
_memorywrite($Godmode,$open,"3488155002","Long")
EndIf
Case $Checkbox4
If GUICtrlRead($Checkbox4) = 4 Then
_memorywrite($Conquest,$open,"2348565970","Long")
Else
_memorywrite($Conquest,$open,"990136971","Long")
EndIf
EndSwitch
WEnd
Func _MemoryScan($ah_Handle, $pattern, $after = False, $iv_addrStart = 0x00000000, $iv_addrEnd = 0X0FFFFFFF, $step = 51200)
If Not IsArray($ah_Handle) Then
SetError(1)
Return -1
EndIf
$pattern = StringRegExpReplace($pattern, "[^0123456789ABCDEFabcdef.]", "")
If StringLen($pattern) = 0 Then
SetError(2)
Return -2
EndIf
For $addr = $iv_addrStart To $iv_addrEnd Step $step - (StringLen($pattern) / 2)
StringRegExp(_MemoryRead($addr, $ah_Handle, "byte[" & $step & "]"), $pattern, 1, 2)
If Not @error Then
If $after Then
Return StringFormat("0x%.8X", $addr + ((@extended - 2) / 2))
Else
Return StringFormat("0x%.8X", $addr + ((@extended - StringLen($pattern) - 2) / 2))
EndIf
EndIf
Next
Return -3
EndFunc ;==>_MemoryScan
And i get this "Warning : $open: possibly used before declaration.
Error : $open: undeclared global variable" at this line :
_memorywrite($InfSp,$open,"2348565979","Long")