segue o codigo
Code: Select all
chatid := "" ; replace XXXXXXX with your chat_id
text := "O valor na variavel chamada Var %life% "
param := "chat_id=" chatid "&text=" text
str =https://api.telegram.org/bot/sendmessage? ; replace XXXXXXX with your API token
;msgbox, % url_tovar(str, param) ; this is useful if you need to return data
#include <classMemory>
#SingleInstance,Force
#NoEnv
if (_ClassMemory.__Class != "_ClassMemory")
{
msgbox class memory not correctly installed.
ExitApp
}
mem := new _ClassMemory("ahk_exe ldvboxheadless.exe", "", hProcessCopy)
if !IsObject(mem)
{
if (hProcess = "")
msgbox OpenProcess failed. If the target process has admin rights, then the script also needs to be ran as admin. Consult A_LastError for more information.
else msgbox The program isn't running (not found) or you passed an incorrect program identifier parameter.
ExitApp
}
SetFormat, float, 0.0
addressmana:= 0x664F7CD8
settimer, menu, on
menu:
SetFormat, float, 0.0
life:= mem.read(addressmana - 0x18,"Int" )
url_tovar(str, param)
return
url_tovar(URL, param) {
WebRequest := ComObjCreate("WinHttp.WinHttpRequest.5.1")
WebRequest.Open("POST", URL)
WebRequest.SetRequestHeader("Content-Type", "application/x-www-form-urlencoded")
WebRequest.Send(param)
res := WebRequest.ResponseText
return res
}
return
Code: Select all
text := "O valor na variavel chamada Var life" . life