Rev 10 | Go to most recent revision | Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
9 | daniel-mar | 1 | |
2 | Annotations for the Aysalia DOS I & II source codes |
||
3 | =================================================== |
||
4 | |||
5 | CALLING FLOW |
||
6 | ------------ |
||
7 | |||
8 | When running under Windows: |
||
9 | |||
10 | AyDos.exe (32 Bit PE) --> DOSBox (32 Bit PE) --> AyDos.exe (16 Bit COM) --> AyDos.mnu (16 Bit MZ) --> AyDos1/2.gam (16 Bit MZ) |
||
11 | |||
12 | 1. AyDos.exe (32 Bit PE) calls DOSBox.exe (32 Bit PE) with config DOSBox.conf |
||
13 | 2. DOSBox.conf starts AyDos.exe (16 Bit MZ) as autostart |
||
14 | 3. AyDos.exe (16 Bit COM) calls AyDos.mnu (16 Bit MZ) |
||
15 | 4. AyDos.mnu (16 Bit MZ) shows a menu and calls AyDos1.gam or AyDos2.gam (both 16 Bit MZ) |
||
16 | |||
17 | When running under DOS: |
||
18 | |||
19 | AyDos.exe (16 Bit COM) --> AyDos.mnu (16 Bit MZ) --> AyDos1/2.gam (16 Bit MZ) |
||
20 | |||
21 | 1. AyDos.exe (16 Bit COM) calls AyDos.mnu (16 Bit MZ) |
||
22 | 2. AyDos.mnu (16 Bit MZ) shows a menu and calls AyDos1.gam or AyDos2.gam (both 16 Bit MZ) |
||
23 | |||
24 | |||
25 | AYDOS.EXE |
||
26 | --------- |
||
27 | |||
28 | AyDos.exe is a "fat binary" which can be called by DOS and Windows. |
||
29 | |||
30 | In Windows mode, it calls DOSBox.exe with the arguments "-noconsole -conf DOSBox.conf" and |
||
31 | the working directory being the directory where the EXE file is located. |
||
32 | |||
33 | In DOS mode, it executes the application "AYDOS.MNU" (which is actually a COM-file |
||
34 | containing the menu code that will eventually call AYDOS1.GAM or AYDOS2.GAM which are |
||
35 | actually MZ-executables). |
||
36 | |||
37 | To create this fat binary, do the following: |
||
38 | |||
39 | 1. Compile AyDos.exe with Delphi |
||
40 | |||
41 | 2. Compile DosStub.com with TASM |
||
42 | |||
43 | 3. With an hex editor, copy the contents of DosStub.com into AyDos.exe to offset 0x40 |
||
44 | |||
45 | |||
46 | AYDOS1.GAM and AYDOS2.GAM |
||
47 | ------------------------- |
||
48 | |||
49 | These games were developed and compiled in QuickBasic, but unfortunately the source code is lost. |
||
50 | |||
51 | The EXE files have been modified with a hex editor to fix some small issues. |
||
52 | A side effect of one fix is that the video mode is not reset when the game exists. |
||
53 | Therefore, the EXE files have been renamed to GAM and will be called by the menu/launcher executable, |
||
54 | which resets the video mode correctly, in addition in showing a menu. |
||
55 | |||
56 | |||
57 | DISTRIBUTE |
||
58 | ---------- |
||
59 | |||
60 | AyDos.exe |
||
61 | AyDos.mnu |
||
62 | AyDos1.gam |
||
63 | AyDos2.gam |
||
64 | DOSBox.exe |
||
65 | DOSBox.conf |
||
66 | SDL.dll (required by DOSBox) |
||
67 | SDL_net.dll (required by DOSBox) |