Rev 16 | Details | Compare with Previous | 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 | |||
29 | daniel-mar | 8 | When running under Windows that supports DOXBox: |
9 | daniel-mar | 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 | |||
29 | daniel-mar | 17 | When running under Windows that does not support DOSBox (only Windows 95): |
18 | |||
19 | AyDos.exe (32 Bit PE) --> AyDos.mnu (16 Bit MZ) --> AyDos1/2.gam (16 Bit MZ) |
||
20 | |||
21 | 1. AyDos.exe (32 Bit PE) calls AyDos.mnu (16 Bit MZ) by temporarily renaming it to AyDos.com |
||
22 | 2. AyDos.mnu (16 Bit MZ) shows a menu and calls AyDos1.gam or AyDos2.gam (both 16 Bit MZ) |
||
23 | |||
9 | daniel-mar | 24 | When running under DOS: |
25 | |||
26 | AyDos.exe (16 Bit COM) --> AyDos.mnu (16 Bit MZ) --> AyDos1/2.gam (16 Bit MZ) |
||
27 | |||
28 | 1. AyDos.exe (16 Bit COM) calls AyDos.mnu (16 Bit MZ) |
||
29 | 2. AyDos.mnu (16 Bit MZ) shows a menu and calls AyDos1.gam or AyDos2.gam (both 16 Bit MZ) |
||
30 | |||
31 | |||
32 | AYDOS.EXE |
||
33 | --------- |
||
34 | |||
35 | AyDos.exe is a "fat binary" which can be called by DOS and Windows. |
||
36 | |||
37 | In Windows mode, it calls DOSBox.exe with the arguments "-noconsole -conf DOSBox.conf" and |
||
38 | the working directory being the directory where the EXE file is located. |
||
16 | daniel-mar | 39 | It also centers the DOSBox window and changes its window title and icon at runtime. |
9 | daniel-mar | 40 | |
41 | In DOS mode, it executes the application "AYDOS.MNU" (which is actually a COM-file |
||
42 | containing the menu code that will eventually call AYDOS1.GAM or AYDOS2.GAM which are |
||
43 | actually MZ-executables). |
||
44 | |||
45 | To create this fat binary, do the following: |
||
46 | |||
47 | 1. Compile AyDos.exe with Delphi |
||
48 | |||
49 | 2. Compile DosStub.com with TASM |
||
50 | |||
51 | 3. With an hex editor, copy the contents of DosStub.com into AyDos.exe to offset 0x40 |
||
52 | |||
53 | |||
54 | AYDOS1.GAM and AYDOS2.GAM |
||
55 | ------------------------- |
||
56 | |||
57 | These games were developed and compiled in QuickBasic, but unfortunately the source code is lost. |
||
58 | |||
59 | The EXE files have been modified with a hex editor to fix some small issues. |
||
60 | A side effect of one fix is that the video mode is not reset when the game exists. |
||
61 | Therefore, the EXE files have been renamed to GAM and will be called by the menu/launcher executable, |
||
62 | which resets the video mode correctly, in addition in showing a menu. |
||
63 | |||
64 | |||
65 | DISTRIBUTE |
||
66 | ---------- |
||
67 | |||
68 | AyDos.exe |
||
69 | AyDos.mnu |
||
70 | AyDos1.gam |
||
71 | AyDos2.gam |
||
72 | DOSBox.exe |
||
73 | DOSBox.conf |
||
74 | SDL.dll (required by DOSBox) |
||
75 | SDL_net.dll (required by DOSBox) |