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 


Need help with ComboBox

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking
View previous topic :: View next topic  
Author Message
RageRBoy
Newbie cheater
Reputation: 0

Joined: 04 Jan 2018
Posts: 10

PostPosted: Sat Mar 10, 2018 8:49 am    Post subject: Need help with ComboBox Reply with quote

So. How i can set a item from combobox to auto assemble code?
Back to top
View user's profile Send private message
FreeER
Grandmaster Cheater Supreme
Reputation: 53

Joined: 09 Aug 2013
Posts: 1091

PostPosted: Sat Mar 10, 2018 11:16 am    Post subject: Reply with quote

too generic.

Code:
[ENABLE]
["Tutorial-i386.exe"+1FD5D0]+480:
  dd $UDF1.CECheckbox1.State*1F4
 
[DISABLE]
["Tutorial-i386.exe"+1FD5D0]+480:
{$lua}
  local value
  if UDF1.CECheckbox1.Checked then
    value = 750
  else
    value = 250
  end
  if not value then return 'db *' else
  return ('dd %x'):format(value) end
{$asm}


Code:
-- generic checkbox handler
local checkboxChangedHandler = function(sender)
  local al = AddressList or getAddressList()
  local mr = al.getMemoryRecordByDescription(sender.Name)
  if not mr then return end
  AutoAssemble(([[
%x:
  dd %x
]]):format(mr.currentAddress, sender.Checked and 500 or 100))
end

for i=0,UDF1.ComponentCount-1 do
  local c = UDF1.Component[i]
  if c.ClassName == 'TCECheckBox' then
    c.OnChange = checkboxChangedHandler
  end
end

_________________
https://github.com/FreeER/ has a few CE related repos
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking 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