Solved help, issue with android

Status
Not open for further replies.

·҉ dollaz·҉. .

Approved iModder
Original poster
Approved iModder
Mar 26, 2021
159
1,815
193
Somewhere
alright so I've been modding android to learn it. Today I tried setting a function pointer. Im using the lgl menu. Heres my pointer:

C++:
bool (*get_isMine)(void *instance) = (bool (*)(void *))getAbsoluteAddress(targetLibName, 0x914014);

bool test;
here is my hook:

C++:
void (*old_Update)(void *instance);
void Update(void *instance) {
    bool isMine = get_isMine(instance);
    if (test) {
        if (isMine == true){ //separated cuz on ios the game didnt work using if(test && isMine){
            *(bool *) ((uint32_t) instance + 0xA9) = true;
    }
}
    return old_Update(instance);
}
here is the hook for the update, yes its in the right place:

C++:
 HOOK("0x8463E1", Update, old_Update);
here is the case section:

C++:
switch (featNum) {
        case 0:
            test = boolean;
            break;

         }
    }
}
I made the menu with a different function without using function pointers and it worked fine, as soon as I use pointers the menu fucks up and the game freezes, I even tried setting a pointer to the function I used when the menu worked, and it would freeze. idk if its the way I did it or if Its the pointers, but I need help
 

Yaskashije

PMT Elite Modder
Staff member
Modding-Team
Sep 9, 2018
4,413
839,653
1,213
Minkowski Space
You are assigning the function pointer in the wrong place.
You have to assign it along with the hooks.

Check already existing tutorias for these subte differences between iOS and Android.
 
Status
Not open for further replies.