|
Cheat Engine The Official Site of Cheat Engine
|
View previous topic :: View next topic |
Author |
Message |
mrjunior Newbie cheater Reputation: 1
Joined: 07 Jul 2018 Posts: 12
|
Posted: Sat Jul 07, 2018 3:13 pm Post subject: Changing few record's valueto constant numbers when I need |
|
|
Hey there, I have a CE table, and there around 10 records with values, which depends of target I've choose, and I need to set record's values to a known values, to make few targets kinda same, if I'll froze the values, this will change any target I choise anytime, but I need kind of 'button' to change values when i want to. Is that hard to realize? And how can I?
- Excuse me for my poor english.
|
|
Back to top |
|
|
FreeER Grandmaster Cheater Supreme Reputation: 53
Joined: 09 Aug 2013 Posts: 1091
|
Posted: Sun Jul 08, 2018 2:12 pm Post subject: |
|
|
Code: | {$lua}
local names = {'record1', 'record2', ...}
local value = 'your_known_value'
[ENABLE]
for _, name in ipairs(names) do
local mr = AddressList.getMemoryRecordByName(name)
mr.Value = value
mr.Active = true -- freeze
end
[DISABLE]
for _, name in ipairs(names) do
local mr = AddressList.getMemoryRecordByName(name)
mr.Active = false -- unfreeze
end |
now you have a script that you can enable to set and freeze and disable to unfreeze.
To increase all their values by one you could use something like:
Code: | {$lua}
local names = {'record1', 'record2', ...}
[ENABLE]
for _, name in ipairs(names) do
local mr = AddressList.getMemoryRecordByName(name)
local value = tonumber(mr.Value)
mr.Value = value+1
end
local t = createTimer()
t.Interval = 50 -- in 50 milliseconds
t.OnTimer = function(t)
t.destroy() -- run once
memrec.Active = false -- auto disable this script
end
[DISABLE] |
You could also set a hotkey to enable it and each type you press the hotkey the values would increase by 1.
_________________
|
|
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
|
|