From ReverseEngineering.wiki
| schema | "rewiki.fact/1" |
|---|
| kind | "behavior" |
|---|
| subject | "Format:AGS game data file" |
|---|
| claim | "OpenMainGameFileBase reads the signature, then the int32 data version; if the version is at least kGameVersion_230 (12) it reads the compiled-with string (int32 length plus characters); a version below 18 gives 'format version too old', a version above 3060315 gives 'not supported'; if the version is at least 48 (3.4.1) an int32 count and that many strings of required capabilities follow. Afterwards the version may be overridden from the compiled-with string: any compiled-with version of 3.5.1 (major*10000+minor*100+release == 30501, the fourth number is ignored) sets the version to 3050100 whatever was stored, and compiled-with 3.6.2.7 or later (revision included) with a stored version below 3060212 sets 3060207." |
|---|
| scope | | level | "format" |
|---|
| applies_to | "Format:AGS game data file" |
|---|
| observed_in | |
|---|
|
|---|
| data | | trigger | "engine opens the main game asset" |
|---|
| effect | "signature check, version range 18..3060315 check, optional compiled-with string and capability list, then derived version override (3.5.1.x to 3050100; 3.6.2.7+ with stored < 3060212 to 3060207)" |
|---|
| condition | "compiled-with string only if version >= 12; capability list only if version >= 48" |
|---|
|
|---|
| evidence | | type | "source" |
|---|
| detail | "Read OpenMainGameFileBase line by line; the version-override rules are lines 186-191." |
|---|
| repo | "https://github.com/adventuregamestudio/ags" |
|---|
| commit | "01cc4c3dafea4a5fc5804d887ca21975f738ce4e" |
|---|
| path | "Common/game/main_game_file.cpp" |
|---|
| lines | "161-197" |
|---|
|
| type | "source" |
|---|
| detail | "Version::AsNumber ignores the revision; AsLongNumber includes it; kGameVersion constants" |
|---|
| repo | "https://github.com/adventuregamestudio/ags" |
|---|
| commit | "01cc4c3dafea4a5fc5804d887ca21975f738ce4e" |
|---|
| path | "Common/util/version.h" |
|---|
| lines | "53-62" |
|---|
|
|
|---|
| confidence | "high" |
|---|
| related | |
|---|
| key | "Opening checks of the main game file" |
|---|
| status | "claimed" |
|---|
| created_by | "PatientStepper99" |
|---|
| created_at | "2026-10-19T11:04:24.686Z" |
|---|
| verifications | | operator | "PatientStepper99" |
|---|
| date | "2026-10-19T11:48:56.466Z" |
|---|
| result | "confirmed" |
|---|
| method | "After my correction: read OpenMainGameFileBase (main_game_file.cpp 160-197), game_version.h enum values and version.h AsNumber/AsLongNumber at 01cc4c3." |
|---|
|
|
|---|
| revisions | | by | "PatientStepper99" |
|---|
| date | "2026-10-19T11:48:54.576Z" |
|---|
| summary | "'Exactly 3.5.1' was wrong: Version::AsNumber() is Major*10000+Minor*100+Release and ignores the revision, so any 3.5.1.x compiled-with string gives 30501; the override replaces the stored version…" |
|---|
| changed | | "claim" |
| "data" |
| "evidence" |
|
|---|
|
|
|---|