pmtcanavari
Rookie
Hi everyone, i got a question. i was modding a game but i have to change 2 offsets with a button and i dont know how to do that. can u guys help me?
		
		
	
	
		
	
	
		
			
		
		
	
				
			
			
				Last edited: 
			
		
	
								
								
									
	
		
			
		
		
	
	
	
		
			
		
		
	
								
							
							 if(instance != NULL && hack1) // Check if instance isn't NULL to prevent crashes
    {
        return false; // If instance isn't NULL, then make my health 999999
    }
    if(instance != NULL && hack1) // Check if instance isn't NULL to prevent crashes
    {
        return false; // If instance isn't NULL, then make my health 999999
    }
	//example
struct My_Patches {
    MemoryPatch patch1, patch2;
} hexPatches;
//put this where the other ones are in the menu
hexPatches.patch1 = MemoryPatch::createWithHex(targetLibName, //Normal obfuscate
                                                  string2Offset(OBFUSCATE("0x000000")),
                                                  OBFUSCATE("9A 02 00 E3 1E FF 2F E1"));
hexPatches.patch2 = MemoryPatch::createWithHex(targetLibName, //Normal obfuscate
                                                  string2Offset(OBFUSCATE("0x000000")),
                                                  OBFUSCATE("9A 02 00 E3 1E FF 2F E1"));
//do this in the case/break
case 1:
            feature1 = boolean;
            if (feature1) {
                hexPatches.patch1.Modify();
                hexPatches.patch2.Modify();
            } else {
                hexPatches.patch1.Restore();
                hexPatches.patch2.Restore();
            }
            break;
	thank you so much man, it worked for meSince nobody has given you the correct solution yet, I will try. Assuming you use LGL.
Here:
C++://example struct My_Patches { MemoryPatch patch1, patch2; } hexPatches; //put this where the other ones are in the menu hexPatches.patch1 = MemoryPatch::createWithHex(targetLibName, //Normal obfuscate string2Offset(OBFUSCATE("0x000000")), OBFUSCATE("9A 02 00 E3 1E FF 2F E1")); hexPatches.patch2 = MemoryPatch::createWithHex(targetLibName, //Normal obfuscate string2Offset(OBFUSCATE("0x000000")), OBFUSCATE("9A 02 00 E3 1E FF 2F E1")); //do this in the case/break case 1: feature1 = boolean; if (feature1) { hexPatches.patch1.Modify(); hexPatches.patch2.Modify(); } else { hexPatches.patch1.Restore(); hexPatches.patch2.Restore(); } break;
but im not sure what you are using to make this cheat, if this works then great but some more details would be appreciated
it worked but when i add another button its not working, only one button is working. what should i do?Since nobody has given you the correct solution yet, I will try. Assuming you use LGL.
Here:
C++://example struct My_Patches { MemoryPatch patch1, patch2; } hexPatches; //put this where the other ones are in the menu hexPatches.patch1 = MemoryPatch::createWithHex(targetLibName, //Normal obfuscate string2Offset(OBFUSCATE("0x000000")), OBFUSCATE("9A 02 00 E3 1E FF 2F E1")); hexPatches.patch2 = MemoryPatch::createWithHex(targetLibName, //Normal obfuscate string2Offset(OBFUSCATE("0x000000")), OBFUSCATE("9A 02 00 E3 1E FF 2F E1")); //do this in the case/break case 1: feature1 = boolean; if (feature1) { hexPatches.patch1.Modify(); hexPatches.patch2.Modify(); } else { hexPatches.patch1.Restore(); hexPatches.patch2.Restore(); } break;
but im not sure what you are using to make this cheat, if this works then great but some more details would be appreciated
Bypass = jboolean1;
            if (Bypass) {
                PMT.Bypass.Modify();
    PMT.AntiBan.Modify();
            } else {
                PMT.Bypass.Restore();
    PMT.AntiBan.Restore();
            }
            break;
  
   case 2:
   AntiBanx = jboolean1;
            if (AntiBanx) {
                PMT.AntiBanx.Modify();
            } else {
                PMT.AntiBanx.Restore();
            }
            break;
PMT.Bypass = MemoryPatch::createWithHex("libil2cpp.so",0xB321100,"00 04 A0 E3");
PMT.AntiBan = MemoryPatch::createWithHex("libil2cpp.so",0x23E43D8,"00 10 A0 E3");
PMT.AntiBanx = MemoryPatch::createWithHex("libil2cpp.so",0x22438CC,"3D 32 17 3F");
	This is a little trimmed up, but im assuming it looks like this?it worked but when i add another button its not working, only one button is working. what should i do?
C:Bypass = jboolean1; if (Bypass) { PMT.Bypass.Modify(); PMT.AntiBan.Modify(); } else { PMT.Bypass.Restore(); PMT.AntiBan.Restore(); } break; case 2: AntiBanx = jboolean1; if (AntiBanx) { PMT.AntiBanx.Modify(); } else { PMT.AntiBanx.Restore(); } break; PMT.Bypass = MemoryPatch::createWithHex("libil2cpp.so",0xB321100,"00 04 A0 E3"); PMT.AntiBan = MemoryPatch::createWithHex("libil2cpp.so",0x23E43D8,"00 10 A0 E3"); PMT.AntiBanx = MemoryPatch::createWithHex("libil2cpp.so",0x22438CC,"3D 32 17 3F");
 case 1:
Bypass = jboolean1;
       if (Bypass) {
         PMT.Bypass.Modify();
         PMT.AntiBan.Modify();
       } else {
         PMT.Bypass.Restore();
         PMT.AntiBan.Restore();
       }
       break;
  case 2:
  AntiBanx = jboolean1;
        if (AntiBanx) {
           PMT.AntiBanx.Modify();
        } else {
           PMT.AntiBanx.Restore();
        }
        break;
	idk actually because im using another theme, not the LGL. so its like that in that theme.This is a little trimmed up, but im assuming it looks like this?
May I ask what jboolean1 is? Because normally with LGL you would just doC++:case 1: Bypass = jboolean1; if (Bypass) { PMT.Bypass.Modify(); PMT.AntiBan.Modify(); } else { PMT.Bypass.Restore(); PMT.AntiBan.Restore(); } break; case 2: AntiBanx = jboolean1; if (AntiBanx) { PMT.AntiBanx.Modify(); } else { PMT.AntiBanx.Restore(); } break;
AntiBanx = boolean;
If it has the same method to add features, try adding a specific case number to the buttonidk actually because im using another theme, not the LGL. so its like that in that theme.
so the problem is that, lets say i created 2 button. first button is working but second one is not. idk why
OBFUSCATE("1_ButtonOnOff_Test"),