Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


popupping CE in a more confortable way

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting
View previous topic :: View next topic  
Author Message
danrevella
Master Cheater
Reputation: 2

Joined: 11 Jun 2008
Posts: 290

PostPosted: Wed Jan 27, 2016 5:39 am    Post subject: popupping CE in a more confortable way Reply with quote

Hi!!
This post is not for you guru.... Wink
This is a post for a newbie only.....

Every time we need to use CE on a game we have to:
run CE
run the game
Alt-tabbing to CE
select the right process
perform the necessary operations
Alt-tabbing again to the game (maybe the game sometime crash....)
Here is what I propose with my script:
run CE and active my script who active an hotkey
run the game
press the hotkey
now CE will popup, auto select the game process, and stop it setting speedhack to 0.0
now perform what you need in CE
press again the hotkey, CE hide and you return to your (now unpaused ) game.

I have experimented that this procedure is much enjoyable in special way when you have to perform changed/unchanged value search, were may be enough difficult to perform in fast time , in special way alt-tabbing may be tedious....
Here is the code:




Code:
{$Asm}
[ENABLE]
{$Lua}
primavolta=true;
function toggleSpHack()
  if primavolta then
  local mygame=getForegroundProcess();
  openProcess(mygame);
  speed = 1.0
  primavolta=nil
  end

  if speed == 0.0 then speed = 1.0
  speedhack_setSpeed(speed)
  hideAllCEWindows()
                  else   speed = 0.0
                  speedhack_setSpeed(speed)
                  unhideMainCEwindow()
  end--end if speed
end--end function

pauseHotkey = createHotkey(toggleSpHack,VK_F12)

{$ASM}
[DISABLE]
{$Lua}
speedhack_setSpeed(1.0)
primavolta=true
pauseHotkey.destroy();
{$Asm}


it is in form of CE table, but may be converted in full lua in very simply way

I hope this help....



CE_popup.CT
 Description:

Download
 Filename:  CE_popup.CT
 Filesize:  982 Bytes
 Downloaded:  518 Time(s)

Back to top
View user's profile Send private message
LastExceed
Expert Cheater
Reputation: 1

Joined: 05 Nov 2014
Posts: 130

PostPosted: Wed Jan 27, 2016 8:17 am    Post subject: Reply with quote

thats actually quite useful! maybe you can also make use of fsSystemStayOnTop...
Back to top
View user's profile Send private message
danrevella
Master Cheater
Reputation: 2

Joined: 11 Jun 2008
Posts: 290

PostPosted: Wed Jan 27, 2016 8:38 am    Post subject: Reply with quote

chris20194 wrote:
thats actually quite useful! maybe you can also make use of fsSystemStayOnTop...

Many thanks!!!
BTW i have try to add getMainForm().formStyle="fsSystemStayOnTop" , but it does not work if the game run in full screen.
Back to top
View user's profile Send private message
pozzum
Newbie cheater
Reputation: 0

Joined: 19 Jun 2015
Posts: 22

PostPosted: Sun Jan 31, 2016 3:20 pm    Post subject: Reply with quote

I'm pretty new at this stuff, how would I take this script and input it into lua for a trainer?

I currently have a little form that I'd like to be able to have pop up in the way you are describing.

my first attempts didn't seem to generate the desired results.

Any help would be appreciated thanks.
Back to top
View user's profile Send private message
danrevella
Master Cheater
Reputation: 2

Joined: 11 Jun 2008
Posts: 290

PostPosted: Mon Feb 01, 2016 4:12 am    Post subject: Reply with quote

pozzum wrote:
I'm pretty new at this stuff, how would I take this script and input it into lua for a trainer?

I currently have a little form that I'd like to be able to have pop up in the way you are describing.

my first attempts didn't seem to generate the desired results.

Any help would be appreciated thanks.


In other way you want a trainer that when you press an hotkey, it get the process of the game, and then popup?
Have I understand?
Back to top
View user's profile Send private message
pozzum
Newbie cheater
Reputation: 0

Joined: 19 Jun 2015
Posts: 22

PostPosted: Mon Feb 01, 2016 11:18 am    Post subject: Reply with quote

danrevella wrote:
pozzum wrote:
I'm pretty new at this stuff, how would I take this script and input it into lua for a trainer?

I currently have a little form that I'd like to be able to have pop up in the way you are describing.

my first attempts didn't seem to generate the desired results.

Any help would be appreciated thanks.


In other way you want a trainer that when you press an hotkey, it get the process of the game, and then popup?
Have I understand?


The trainer already has a auto attach process and is designed to be opened after the game is started.

So I'd like for it to say pop up when I press the hotkey and then hide away when I press the hotkey again.

Hopefully that's more clear...
Back to top
View user's profile Send private message
danrevella
Master Cheater
Reputation: 2

Joined: 11 Jun 2008
Posts: 290

PostPosted: Mon Feb 01, 2016 11:50 am    Post subject: Reply with quote

pozzum wrote:


The trainer already has a auto attach process and is designed to be opened after the game is started.

So I'd like for it to say pop up when I press the hotkey and then hide away when I press the hotkey again.

Hopefully that's more clear...

Please excuse, but when you selecet: generate generic trainer lua script from table, the option you require does exist: "popup trainer on keypress", you only have to click the option, try to generate the script only, ad you'll find the code:

Code:
getAutoAttachList().add("AutoHotkey.exe")
function popupTrainerHotkeyFunction()
  CETrainer.show()
end
createHotkey(popupTrainerHotkeyFunction, 123)

123 is the corrispondent of the key F12 f.e.
Back to top
View user's profile Send private message
pozzum
Newbie cheater
Reputation: 0

Joined: 19 Jun 2015
Posts: 22

PostPosted: Tue Feb 02, 2016 7:55 am    Post subject: Reply with quote

danrevella wrote:
pozzum wrote:


The trainer already has a auto attach process and is designed to be opened after the game is started.

So I'd like for it to say pop up when I press the hotkey and then hide away when I press the hotkey again.

Hopefully that's more clear...

Please excuse, but when you selecet: generate generic trainer lua script from table, the option you require does exist: "popup trainer on keypress", you only have to click the option, try to generate the script only, ad you'll find the code:

Code:
getAutoAttachList().add("AutoHotkey.exe")
function popupTrainerHotkeyFunction()
  CETrainer.show()
end
createHotkey(popupTrainerHotkeyFunction, 123)

123 is the corrispondent of the key F12 f.e.


Ok awesome thanks, I hadn't opened that menu before so I'll try that tonight.

Thanks for your time.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Lua Scripting All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites