View previous topic :: View next topic |
Author |
Message |
Cissamannen Cheater Reputation: 0
Joined: 16 Jul 2009 Posts: 36
|
Posted: Wed Apr 26, 2017 12:48 pm Post subject: Multiple selection in dropdown - Add selected values 2gether |
|
|
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
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 |
|
|
FreeER Grandmaster Cheater Supreme Reputation: 53
Joined: 09 Aug 2013 Posts: 1091
|
Posted: Wed Apr 26, 2017 4:20 pm Post subject: |
|
|
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 |
|
|
Dark Byte Site Admin Reputation: 458
Joined: 09 May 2003 Posts: 25296 Location: The netherlands
|
Posted: Wed Apr 26, 2017 4:30 pm Post subject: |
|
|
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 |
|
|
Cissamannen Cheater Reputation: 0
Joined: 16 Jul 2009 Posts: 36
|
Posted: Wed Apr 26, 2017 7:31 pm Post subject: |
|
|
Phew that was alot to digest.
Gonna have to read this tomorrow when im more awake lol!
|
|
Back to top |
|
|
|