// Detect It Easy: detection rule file
// Author: BJNFNE <bjnfne@web.de>

// https://www.adventuregamestudio.co.uk/
meta("game engine", "Adventure Game Studio (AGS)");

function detect() {
    if (PE.compareOverlay("434c49421a")) {
        bDetected = true;
    } else if (PE.getVersionStringInfo("Comment") == "This game was created using AGS - http://www.adventuregamestudio.co.uk/") {
        bDetected = true;
    } else if (PE.getVersionStringInfo("FileDescription") == "Adventure Game Studio run-time engine") {
        bDetected = true;
    } else if (PE.getVersionStringInfo("ProductName") == "Made with Adventure Game Studio") {
        bDetected = true;
    }

    if (bDetected) sVersion = File.cleanString(PE.getFileVersion());

    return result();
}