// Author: DosX
// E-Mail: collab@kay-software.ru
// GitHub: https://github.com/DosX-dev
// Telegram: @DosX_dev

init("protector", "DexProtector");

function detect(bShowType, bShowVersion, bShowOptions) {
    bDetected =
        APK.isArchiveRecordPresent("assets/classes.dex.dat") ||
        APK.isArchiveRecordPresent("assets/dp.arm-v7.so.dat") ||
        APK.isArchiveRecordPresent("assets/dp.arm-v8.so.dat") ||
        APK.isArchiveRecordPresent("assets/dp.arm.so.dat") ||
        APK.isArchiveRecordPresent("assets/dp.mp3") ||
        APK.isArchiveRecordPresent("assets/dp.x86.so.dat") ||
        APK.isArchiveRecordPresent("assets/dp.x86_64.so.dat") ||
        APK.isArchiveRecordPresent("lib/armeabi-v7a/libdexprotector.so") ||
        APK.isArchiveRecordPresent("lib/armeabi/libdexprotector.so") ||
        APK.isArchiveRecordPresent("assets/dp-lib/dp.kotlin-v1.lua.mph") ||
        APK.isArchiveRecordPresent("assets/dexprotect/classes.dex.dat");

    return result(bShowType, bShowVersion, bShowOptions);
}