|
Cheat Engine The Official Site of Cheat Engine
|
View previous topic :: View next topic |
Author |
Message |
Razi Expert Cheater Reputation: 1
Joined: 17 Jan 2018 Posts: 202
|
Posted: Sun May 19, 2019 8:18 am Post subject: Add label and option to CE? |
|
|
1) How to add label, that shows current quantity of memory records near "Table Extras" in the bottom of CE general window (purple rectangle on the screenshot)? I constantly miss this function, when I use Cheat Engine.
2) CE has an option, when we right click with the mouse on the memory record, there is an option: Group config -> Hide children when deactivated.
How to add an option there: Hide children when activated?
Description: |
|
Filesize: |
73.65 KB |
Viewed: |
2908 Time(s) |
|
|
|
Back to top |
|
|
Corroder Grandmaster Cheater Supreme Reputation: 75
Joined: 10 Apr 2015 Posts: 1667
|
Posted: Sun May 19, 2019 11:40 am Post subject: |
|
|
1, To count the sum of address list items.
Code: | addlist = getAddressList()
count = addlist.count
print(count) |
And to add Label (caption change by that function above) then:
Code: | Main = getMainForm()
ThePanel = Main.Panel4
NewLabel = createLabel(ThePanel)
NewLabel.caption = 'Address List Count : '..count
|
But I am not sure what is the component name on CE Main form with 'Table Extras Button' there. I think it should be Panel 4. Also, I am not sure about placing the label as you wish, since all components on Panel 4 set to their client width and height. Maybe adding a new panel is the better solution.
2. Hide children menu will show when doing the right click, of course, if the address list contains parent and children and that can be set via group config.
Here some functions for group config.
Code: | function miHideChildrenClick(mr)
if mr.Options:match("moHideChildren") == nil then
mr.Options = mr.Options.."moHideChildren"
else
mr.Options = mr.Options:gsub("moHideChildren","")
end
end
function miBindActivationClick(mr)
if mr.Options:match("moActivateChildrenAsWell") == nil then
mr.Options = mr.Options.."moActivateChildrenAsWell"
else
mr.Options = mr.Options:gsub("moActivateChildrenAsWell","")
end
end
function miBindDeactivationClick(mr)
if mr.Options:match("moDeactivateChildrenAsWell") == nil then
mr.Options = mr.Options.."moDeactivateChildrenAsWell"
else
mr.Options = mr.Options:gsub("moDeactivateChildrenAsWell","")
end
end
function miRecursiveSetValueClick(mr)
if mr.Options:match("moRecursiveSetValue") == nil then
mr.Options = mr.Options.."moRecursiveSetValue"
else
mr.Options = mr.Options:gsub("moRecursiveSetValue","")
end
end
function miAllowCollapseClick(mr)
if mr.Options:match("moAllowManualCollapseAndExpand") == nil then
mr.Options = mr.Options.."moAllowManualCollapseAndExpand"
else
mr.Options = mr.Options:gsub("moAllowManualCollapseAndExpand","")
end
end
function miManualExpandCollapseClick(mr)
if mr.Options:match("moManualExpandCollapse") == nil then
mr.Options = mr.Options.."moManualExpandCollapse"
else
mr.Options = mr.Options:gsub("moManualExpandCollapse","")
end
end
function optionWrapper(sender)
local sr = al.getSelectedRecords()
for i in pairs(sr) do
if al[i-1].Count > 0 then
if sender.Name == "miHideChildren" then miHideChildrenClick(al[i-1])
elseif sender.Name == "miBindActivation" then miBindActivationClick(al[i-1])
elseif sender.Name == "miBindDeactivation" then miBindDeactivationClick(al[i-1])
elseif sender.Name == "miRecursiveSetValue" then miRecursiveSetValueClick(al[i-1])
elseif sender.Name == "miAllowCollapse" then miAllowCollapseClick(al[i-1])
elseif sender.Name == "miManualExpandCollapse" then miManualExpandCollapseClick(al[i-1])
end
end
end
end
--Events-------------------------------------------------------------------------------------------
mf.miHideChildren.onClick = optionWrapper
mf.miBindActivation.onClick = optionWrapper
mf.miBindDeactivation.onClick = optionWrapper
mf.miRecursiveSetValue.onClick = optionWrapper
mf.miAllowCollapse.onClick = optionWrapper
mf.miManualExpandCollapse.onClick = optionWrapper
|
_________________
Stealing Code From Stolen Code...
And Admit It.. Hmmm....Typically LOL |
|
Back to top |
|
|
Razi Expert Cheater Reputation: 1
Joined: 17 Jan 2018 Posts: 202
|
Posted: Sun May 19, 2019 6:09 pm Post subject: |
|
|
I can create a label on the place where was needed with following code: Code: | Main = getMainForm()
addlist = getAddressList()
ThePanel = Main.Panel4
NewLabel = createLabel(ThePanel)
NewLabel.Left = 405
NewLabel.caption = 'records : '..addlist.count |
But, on what events memory records value should change in the label? Main.OnMouseMove = function() or Main.OnKeyPress = function()? I want to change value when quantity of memory records are changed and when opening a .CT file, without creating a timer. But can't find a solution.
I saw Group Config lua extension before created topic. But, didn't understand how to do what was needed. Don't know what needs to be changed in the following code to achieve what I wanted. Code: | function miHideChildrenClick(mr)
if mr.Options:match("moHideChildren") == nil then
mr.Options = mr.Options.."moHideChildren"
else
mr.Options = mr.Options:gsub("moHideChildren","")
end
end |
|
|
Back to top |
|
|
Corroder Grandmaster Cheater Supreme Reputation: 75
Joined: 10 Apr 2015 Posts: 1667
|
|
Back to top |
|
|
|
|
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
|
|