liten Posted June 10, 2009 Share Posted June 10, 2009 (edited) How do i set a button to when it is clicked it changes the value stored in an address, such as, if Button 3 is clicked it will change the value in 0x00777000 to what ever i tell it to be.? my code was Func RadioSpeed3() SetPrivilege("SeDebugPrivilege", 1) $ID = _MemoryOpen(ProcessExists("Program.exe")) If BitAnd(GUICtrlRead($Radio3), $GUI_CHECKED) = $GUI_CHECKED Then _MemoryWrite($CTT, $ID, 200) Else EndIf _MemoryClose($ID) But dosent work Edited June 10, 2009 by liten My UDF:Freeze.au3-Freeze values like CE, ML, ETC[i][/i][u][/u] Link to comment Share on other sites More sharing options...
Authenticity Posted June 10, 2009 Share Posted June 10, 2009 Either: expandcollapse popup#include <GUIConstantsEx.au3> ; ... ; .. ; . Global $Radio3 $Radio3 = GUICtrlCreateRadio('Speed', 20, 20) ; . ; .. ; ... While 1 Switch GUIGetMsg() Case $Radio3 RadioSpeed3() Case $GUI_EVENT_CLOSE GUIDelete() ExitLoop EndSwitch WEnd Exit Func RadioSpeed3() SetPrivilege("SeDebugPrivilege", 1) $ID = _MemoryOpen(ProcessExists("Program.exe")) If BitAnd(GUICtrlRead($Radio3), $GUI_CHECKED) = $GUI_CHECKED Then _MemoryWrite($CTT, $ID, 200) EndIf _MemoryClose($ID) EndFuncoÝ÷ ÚÚºÚ"µÍÚ[ÛYH ÑÕRPÛÛÝ[Ñ^]LÉÝÂÜ ÌÎNÑÕRSÛ][[ÙIÌÎNËJBÈÈÈÛØ[ ÌÍÚÕRBÛØ[ ÌÍÔY[ÌÂÌÍÚÕRHHÕRPÜX]J ÌÎNÕÝ ÌÎNË BÕRTÙ]Û][ ÌÍÑÕRWÑUSÐÓÔÑK ÌÎN×ÐÛÜÙIÌÎNÊBÌÍÔY[ÌÈHÕRPÝÜX]TY[Ê ÌÎNÔÜYY ÌÎNË BÕRPÝÙ]Û][ ÌÍÔY[ÌË ÌÎNÔY[ÔÜYYÉÌÎNÊBÈÈÈÚ[HBÛY BÑ[BB[ÈY[ÔÜYYÊ BTÙ]][YÙJ ][ÝÔÙQXYÔ][YÙI][ÝËJBIÌÍÒQHÓY[[ÜSÜ[ØÙÜÑ^ÝÊ ][ÝÔÙÜ[K^I][ÝÊJBRY][ ÕRPÝXY ÌÍÔY[ÌÊK ÌÍÑÕRWÐÒPÒÑQ HH ÌÍÑÕRWÐÒPÒÑQ[BWÓY[[ÜUÜ]J ÌÍÐÕ ÌÍÒQ BQ[YWÓY[[ÜPÛÜÙJ ÌÍÒQ B[[Â[ÈÐÛÜÙJ BQÕRQ[]J BQ^][[ Link to comment Share on other sites More sharing options...
liten Posted June 10, 2009 Author Share Posted June 10, 2009 (edited) Either: expandcollapse popup#include <GUIConstantsEx.au3> ; ... ; .. ; . Global $Radio3 $Radio3 = GUICtrlCreateRadio('Speed', 20, 20) ; . ; .. ; ... While 1 Switch GUIGetMsg() Case $Radio3 RadioSpeed3() Case $GUI_EVENT_CLOSE GUIDelete() ExitLoop EndSwitch WEnd Exit Func RadioSpeed3() SetPrivilege("SeDebugPrivilege", 1) $ID = _MemoryOpen(ProcessExists("Program.exe")) If BitAnd(GUICtrlRead($Radio3), $GUI_CHECKED) = $GUI_CHECKED Then _MemoryWrite($CTT, $ID, 200) EndIf _MemoryClose($ID) EndFuncƒoÝŠ÷ ÚŠÚºÚ"µÍˆÚ[˜ÛYH ›ÑÕRPÛÛœÝ[Ñ^˜]LÉ™ÝÂ“Ü ˆÌÎNÑÕRSÛ‘]™[[ÙIˆÌÎNËJBŽÈ‹‹‚ŽÈ‹‚ŽÈ‚‘Ûؘ[ ˆÌÍŽÚÕRB‘Ûؘ[ ˆÌÍŽÔ˜Y[Ì‚‰ˆÌÍŽÚÕRHHÕRPÜ™X]J ˆÌÎNÕÝ ˆÌÎNËŒŒ B‘ÕRTÙ]Û‘]™[ ˆÌÍŽÑÕRWÑU‘S•ÐÓÔÑK ˆÌÎN×ÐÛÜÙIˆÌÎNÊB‚‰ˆÌÍŽÔ˜Y[ÌÈHÕRPݛܙX]T˜Y[Ê ˆÌÎNÔÜYY ˆÌÎNËŒŒ B‘ÕRPÝ›Ù]Û‘]™[ ˆÌÍŽÔ˜Y[ÌË ˆÌÎNÔ˜Y[ÔÜYYɈÌÎNÊB‚ŽÈ‚ŽÈ‹‚ŽÈ‹‹‚‚•Ú[HBˆÛY Œ B•Ñ[™‚BB‘[˜È˜Y[ÔÜYYÊ B‚TÙ]š]š[YÙJ œ][ÝÔÙQXYÔš]š[YÙIœ][ÝËJB‚IˆÌÍŽÒQHÓY[[ÜžSÜ[Š›ØÙÜÑ^ÝÊ œ][ÝÔ›Ùܘ[K™^Iœ][ÝÊJB‚RYˆš][™ ÕRPÝ›™XY ˆÌÍŽÔ˜Y[ÌÊK ˆÌÍŽÑÕRWÐÒPÒÑQ HH ˆÌÍŽÑÕRWÐÒPÒÑQ[‚‚BWÓY[[ÜžUÜš]J ˆÌÍŽÐÕ ˆÌÍŽÒQŒ B‚Q[™Y‚‚WÓY[[ÜžPÛÜÙJ ˆÌÍŽÒQ B‘[™[˜Â‚‘[˜ÈÐÛÜÙJ B‚QÕRQ[]J B‚Q^]‘[™[˜ Works thanks, so how would i go about doing this for Slider, to control the value in the addy for slider here is the code im using that dosent work Func ATTS() SetPrivilege("SeDebugPrivilege", 1) $ID = _MemoryOpen(ProcessExists("Program.exe")) _MemoryRead($ATTSS, $ID) = GuiCtrlRead($Slider1) _MemoryClose($ID) EndFunc Edited June 10, 2009 by liten My UDF:Freeze.au3-Freeze values like CE, ML, ETC[i][/i][u][/u] Link to comment Share on other sites More sharing options...
Authenticity Posted June 10, 2009 Share Posted June 10, 2009 What is this code suppose to do? _MemoryRead($ATTSS, $ID) = GuiCtrlRead($Slider1) At least, you're reading the slider value correctly. Link to comment Share on other sites More sharing options...
liten Posted June 10, 2009 Author Share Posted June 10, 2009 What is this code suppose to do? _MemoryRead($ATTSS, $ID) = GuiCtrlRead($Slider1) At least, you're reading the slider value correctly. the codes suppose to make the value of the memory in addy 0x000000 equl to what ever the slier is, so if i move the slider to 300, the value in addy0x000000 will become 300 and so on, i want the slider to control the value of addy 0x000000 My UDF:Freeze.au3-Freeze values like CE, ML, ETC[i][/i][u][/u] Link to comment Share on other sites More sharing options...
Authenticity Posted June 10, 2009 Share Posted June 10, 2009 So your code should be: _MemoryWrite($ATTSS, $ID, GuiCtrlRead($Slider1)) Link to comment Share on other sites More sharing options...
liten Posted June 10, 2009 Author Share Posted June 10, 2009 (edited) So your code should be: _MemoryWrite($ATTSS, $ID, GuiCtrlRead($Slider1))So, like this, if so it dosent work, can you please tell me what i am doing wrong Func ATS() SetPrivilege("SeDebugPrivilege", 1) $ID = _MemoryOpen(ProcessExists("Program.exe")) _MemoryWrite($ATTSS, $ID, GuiCtrlRead($Slider1)) _MemoryClose($ID) EndFunc Edited June 10, 2009 by liten My UDF:Freeze.au3-Freeze values like CE, ML, ETC[i][/i][u][/u] Link to comment Share on other sites More sharing options...
Authenticity Posted June 10, 2009 Share Posted June 10, 2009 (edited) Heh. I see a few mistakes in the code. First, you don't have to change privileges every time the function get called. Second, please take a look in the NomadMemory.au3 library so you can see how to invoke it, the first parameter should be the process ID, the second is the access rights and the third is the new value.Edit: You can use ConsoleWrite() or MsgBox() to inspect the values of variables, functions, etc.. Edited June 10, 2009 by Authenticity Link to comment Share on other sites More sharing options...
liten Posted June 10, 2009 Author Share Posted June 10, 2009 Heh. I see a few mistakes in the code. First, you don't have to change privileges every time the function get called. Second, please take a look in the NomadMemory.au3 library so you can see how to invoke it, the first parameter should be the process ID, the second is the access rights and the third is the new value.Edit: You can use ConsoleWrite() or MsgBox() to inspect the values of variables, functions, etc.. Could you please explain this a little bit more. i am really lost also $ATTS or what ever, is my process ID i just assigned it to that $thingy, i am really lost / confused, could you please help clarify, Exzactly how to do this My UDF:Freeze.au3-Freeze values like CE, ML, ETC[i][/i][u][/u] Link to comment Share on other sites More sharing options...
Authenticity Posted June 10, 2009 Share Posted June 10, 2009 (edited) Sorry, moi mistake, I've been reading both _MemoryWrite() and _MemoryOpen() while posting the previous post. Can you do as suggested with the MsgBox() or ConsoleWrite() to see what is not working because it'll make it easier to spot the wrong code.Edit: By the way, you need to see if you can write to the process memory because if the certain memory has only read access you need to use VirtualProtectEx (API) function to change it, if applicable. Edited June 10, 2009 by Authenticity Link to comment Share on other sites More sharing options...
liten Posted June 10, 2009 Author Share Posted June 10, 2009 Sorry, moi mistake, I've been reading both _MemoryWrite() and _MemoryOpen() while posting the previous post. Can you do as suggested with the MsgBox() or ConsoleWrite() to see what is not working because it'll make it easier to spot the wrong code.Edit: By the way, you need to see if you can write to the process memory because if the certain memory has only read access you need to use VirtualProtectEx (API) function to change it, if applicable.Your gona hate me, hahah , i dont know how to use ConsoleWrite, and i have only use MsgBox on butoons, My UDF:Freeze.au3-Freeze values like CE, ML, ETC[i][/i][u][/u] Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now