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 


Multiple selection in dropdown - Add selected values 2gether

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine
View previous topic :: View next topic  
Author Message
Cissamannen
Cheater
Reputation: 0

Joined: 16 Jul 2009
Posts: 36

PostPosted: Wed Apr 26, 2017 12:48 pm    Post subject: Multiple selection in dropdown - Add selected values 2gether Reply with quote

So!

Another question for you guys. Dont know if its possible without some advance autoassembly or lua scripting that I have no clue how to do Razz

Basicly, what I want is to make these in a dropdown menu where I can select several choices, and make the values adding together in total for that 1 specific address. Is this even possible in a simple way?

The adresses I want is already in a dropdown menu with the current type like this:

00:No Special Rules
01:Open
02:Same
04:Plus
08:Random
10:Sudden Death
20:Retry
40:Same Wall
80:Elemental

This is also for FF8, and the offset for Balamb Garden is: 1CFEAC8
For example, you could put 01, 02, 04, 10 together, by putting value 17 in hex. That would give me 4 options added in card battle menu, instead of just 1 for the selected region.

HOW TO DO IT? D:
Back to top
View user's profile Send private message
FreeER
Grandmaster Cheater Supreme
Reputation: 53

Joined: 09 Aug 2013
Posts: 1091

PostPosted: Wed Apr 26, 2017 4:20 pm    Post subject: Reply with quote

As far as I know it's not possible through the address list without manually adding all the possible combinations (eg. "3:Open+Same"), it should be easy enough via a form and lua however, I created an example in my cheat table for the tutorial (v3.3 x86 version for CE 6.6)

Basically the idea is to enable the option you use the bitwise or operation to set the bit and to disable the option you do a bitwise and operation on the current value with the inverse of the bit value. So if the value is 0 and you want to enable "Same" then you "or" the value 2 to set the bit that represents 2 (10000000 or 00000010 = 10000010 aka 130 or 0x82) to disable it when Same, Plus, and Same Wall are set you "and" the inverse of 2 (inverse aka not 2, 00000010 = 11111101, 01000110 and 11111101 = 01000100). CE/DarkByte has added the lua functions bOr, bAnd, and bNot to help you do the work.

Here's the cheat table with everything unrelated removed: https://www.dropbox.com/s/2cailxz4btidrvn/Tutorial-i386%20-%20flags%20via%20form.CT?dl=0

Just let it run the lua script (or say no and then do it manually after checking it out via the Table->"Show Cheat Table Lua Script" option) and attach to the tutorial on step 2 (you can reopen the form if you close it using "Table->FlagsForm->Restore and Show" or by manually running the script)...

My full tutorial cheat table in case you (or anyone else) is interested: https://www.dropbox.com/s/1pwtgidlua97txa/Tutorial-i386.CT?dl=0

Instructions for this specific example: Enable the "Set flags via form by FreeER (me)" script at the bottom in the "Useful Technique Examples" section to run the code (I prefer not to have CE prompt me to run the lua script every time I open the ct) and attach to the tutorial on step 2

edit: I've updated the tables to demo DB's suggestion (for the full ct there's a header called "Set Flags" now that everything is nested in), note form only updates on "Activation" (when you switch to it) so it will only update if you switch away (click on something else) and then switch back, setting up a timer to update it wouldn't be difficult however.


Last edited by FreeER on Wed Apr 26, 2017 7:53 pm; edited 3 times in total
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 458

Joined: 09 May 2003
Posts: 25296
Location: The netherlands

PostPosted: Wed Apr 26, 2017 4:30 pm    Post subject: Reply with quote

you could also add 8 different addresses of type binary with bitlength 1 and each a different startbit

and then just give each option an on/off dropdown

_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
Cissamannen
Cheater
Reputation: 0

Joined: 16 Jul 2009
Posts: 36

PostPosted: Wed Apr 26, 2017 7:31 pm    Post subject: Reply with quote

Phew that was alot to digest.

Gonna have to read this tomorrow when im more awake lol!
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 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