Please give me an Internet. Please. Pretty Please with sprinkles on top
I have a twitter!! Follow me for regular updates on my mods! https://twitter.com/DamienMiller11
Use the above code. Be sure not to include the mcpe.h file as that is very old. You can delete the whole file from the project.
(by the way MinecraftMuse3, look at the MSHookFunction in the above code. You need to put a (void*) & before the first parameter. Just saying!)
Sorry, I just wrote that up without testing lol
Rollback Post to RevisionRollBack
Please give me an Internet. Please. Pretty Please with sprinkles on top
I have a twitter!! Follow me for regular updates on my mods! https://twitter.com/DamienMiller11
#include <jni.h>
#include <dlfcn.h>
#include <android/log.h>
#include <stdlib.h>
#include <mcpe.h>
#include <Substrate.h>
#define LOG_TAG "versionnamechanger"
#define LOGI(...) ((void)__android_log_print(ANDROID_LOG_INFO, LOG_TAG, __VA_ARGS__))
static std::string (*common$getGameVersion_old)();
static std::string common$getGameVersion_new() {
return "0.11.0";
}
JNIEXPORT jint JNI_OnLoad(JavaVM* vm, void* reserved) {
void* handle = dlopen("libminecraftpe.so", RTLD_LAZY);
void* common$getGameVersionString = dlsym(handle, "_ZN6Common20getGameVersionStringEv");
MSHookFunction(common$getGameVersionString, (void*) &common$getGameVersion_new, (void**) &common$getGameVersion_old);
LOGI("Hello world!");
return JNI_VERSION_1_2;
}
I want to change "v0.10.5 alpha" to "0.11.0".
But this Mcpe-Addon does not work.
I used the addon templater generator by 500ISE.
Ps. The Mcpe Version is 0.10.5, and the Blocklauncher Version is 1.8.3.
Pps. Tips for making Mcpe Addons??
Ppps. Sorry for my bad English..
Tap the link below to sub to my youtube channel:
https://m.youtube.com/channel/UCDPTTeHo67o7-mZiiGh_XKg?debug_prerolls=false&layout=mobile&tsp=1&utcoffset=480
Try this
[main.cpp]
#include <jni.h>
#include <dlfcn.h>
#include <android/log.h>
#include <stdlib.h>
#include <mcpe.h>
#include <Substrate.h>
#include <string> // What you left out
#define LOG_TAG "versionnamechanger"
#define LOGI(...) ((void)__android_log_print(ANDROID_LOG_INFO, LOG_TAG, __VA_ARGS__))
static std::string (*CommonGetGameVersion_old)();
static std::string CommonGetGameVersion_new() {
return "0.11.0";
}
JNIEXPORT jint JNI_OnLoad(JavaVM* vm, void* reserved) {
void* CommonGetGameVersionString = dlsym(RTLD_DEFAULT, "_ZN6Common20getGameVersionStringEv");
MSHookFunction((void*) CommonGetGameVersionString, (void*) CommonGetGameVersion_new, (void**)
CommonGetGameVersion_old);
return JNI_VERSION_1_2;
}
This would work as well:
I have a twitter!! Follow me for regular updates on my mods!
https://twitter.com/DamienMiller11
Use the above code. Be sure not to include the mcpe.h file as that is very old. You can delete the whole file from the project.
(by the way MinecraftMuse3, look at the MSHookFunction in the above code. You need to put a (void*) & before the first parameter. Just saying!)
", sans-serif">Want to get paid for uploading mods?
", sans-serif">Click here
For free Bitcoins, click here!
Sorry, I just wrote that up without testing lol
I have a twitter!! Follow me for regular updates on my mods!
https://twitter.com/DamienMiller11
lol that's fine!
", sans-serif">Want to get paid for uploading mods?
", sans-serif">Click here
For free Bitcoins, click here!
You both left out #include <string>