![]() |
China DOS Union-- Unite DOS · Advance DOS · Grow DOS --Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum |
| Guest | Log in | Register | Members | Search | China DOS Union |
|
中国DOS联盟论坛 The time now is 2026-08-12 04:35 |
47,811 topics / 349,897 posts / today 0 new / 48,256 members |
| DOS学习入门 & 精彩文章 (教学室) » Repost: General Instructions for DOS Games (Text: 无翼在天) |
| Printable Version 12,430 / 14 |
| Floor1 Lydong | Posted 2003-06-06 00:00 |
| 元老会员 Posts 407 Credits 1,468 From 广州 | |
|
General instructions for DOS games
-------------------------------------------------------------------------------- System overview Memory issues Writing config.sys Writing autoexec.bat Display, sound card, and CD-ROM issues Useful tools Since the DOS era is already over, the new generation of gamers rarely comes into contact with the DOS system. Many problems that look very “simple” still leave them helpless. Here I’ll briefly introduce how to play DOS games. Operating systems suitable for playing DOS games dos5.0, dos6.0 (relatively stable older DOS versions, default directory c:\dos) dos6.22 (the final version of pure DOS, default directory c:\dos) dos7.0 (the DOS that comes with win95 and win98, default directory c:\windows\command) In addition, winxp, winnt, and win2000 all have their own Dos command prompt, but they cannot be used as a boot system. If your machine only has these systems, then unfortunately, you can’t play DOS games. Booting and loading Older DOS versions (before dos6.22) load the system files msdos.sys, io.sys, and command.com after startup; none of them can be missing. Then they load the management programs in config.sys and autoexec.bat. If these two files are missing, then you can hardly do anything and can only use the most basic DOS commands. Newer DOS versions (dos7.0 that comes with win95/win98) load the system files io.sys and command.com after startup, while msdos.sys is only used as a boot configuration file. config.sys and autoexec.bat are basically empty files, because the system loads important settings such as emm386, himem, dos, files, etc. by default. Memory basics There are base memory (base memory, 640K), upper memory (upper memory, 384K), expanded memory (expand memory, the user’s total physical memory), and other types. DOS games are generally started in base memory, because there is only 640K, and other resident programs are also placed there. So when it says there is not enough memory, it is usually because the user did not load upper memory and move other programs elsewhere. Those programs are taking up the game’s space, causing the game to display "not enough memory". Games generally do not use upper memory, so if some resident programs such as mouse, mscdex, doskey, gb, etc. are put there, a lot of space can be freed in base memory for the game. Expanded memory is not used to start the game, but to handle large amounts of exchanged data during the game, and has nothing to do with game startup. Sometimes if a game quits halfway through, it may be because there is not enough expanded memory. The most fatal bottleneck for DOS games is memory. It does not intelligently manage memory like windows. All settings have to be adjusted bit by bit by yourself, and early games were designed to use only upper memory and base memory. Even if your expanded memory is 128M, it is still useless—the program design itself simply does not use it. Writing the config.sys file This boot system file can be edited. The most common way is to use the edit command that comes with dos. If your path (this command will be explained later) is not pointing to the wrong place, then you can run “edit config.sys” under c:\ to edit this file. Likewise, you can edit autoexec.bat the same way. The config.sys file manages DOS memory. Common memory management statements are: DEVICE(load management program) DEVICEhigh(load into upper memory) dos(location of system files) files(number of open files) buffers(number of buffers) lastdrive(last drive letter) shell(location of command interpreter) rem (comment) Example explanations: 1, DEVICE=C:\dos\HIMEM.SYS /testmem:off This statement is very important. It loads upper memory management so dos can use upper memory. If your machine is slow, you can add /testmem:off to skip the memory test. 2,DEVICEhigh=C:\dos\EMM386.EXE ram Load emm386 into upper memory. emm386.exe is used to manage expanded memory, and this statement is also very important. The common parameters are ram and noems, meaning use expanded memory and use extended memory. noems can free more base memory than ram, but many programs do not use this noems statement, so its range of use is quite narrow. 3,dos=high,umb This statement is very important. It puts the system files msdos.sys, io.sys, and command.com into upper memory. 4,files=30 The maximum number of files that can be opened at the same time. Some games need to open many data streams at once. If this statement is not set, its default value is 10, and the game may produce errors. 5,buffers=20,8 Set the number of buffers and fast buffers, used to speed up file reading. 6,lastdrive=z Specify the last hard disk drive letter as z, that is to say, you can use drive letters up to z:. Even if you do not have that many partitions, you can use subst,fcd,ramdrive,img and other methods to emulate some hard disk partitions. If this statement is not loaded, the above commands will not take effect. 7,shell=c:\dos\command.com This command exists by default and generally does not need to be loaded. Its function is to specify the dos command interpreter. Normally the default is c:\dos\command.com. If you need Japanese dos or want to use another command interpreter, such as 4dos or ndos, then you need to specify a shell. 8,rem this is a sample rem is a comment statement. No matter what you write after it, dos ignores it. It is often used to disable statements that are temporarily not needed. For example, if you temporarily do not need to load shell=c:\dos\command.com, you only need rem shell=c:\dos\command.com , and dos will skip that line and not execute it. The same applies to autoexec.bat Summary of the config settings usually needed for DOS games: DEVICE=C:\dos\HIMEM.SYS DEVICE=C:\dos\EMM386.EXE ram (or DEVICE=C:\dos\EMM386.EXE noems) dos=high,umb files=30 If you also need a CD-ROM drive to play, you may also need to load the CD-ROM startup program, for example DEVICE=c:\cdrom\VIDE-CDD.SYS /D:MSCD001 , which is usually done by the installer. If you also need a sound card to play, you may also need to load the sound card startup program, for example DEVICE=c:\sound\sbcd.SYS, which is usually done by the installer. Note: the c:\dos mentioned in this article is the default dos directory. If yours is win98 dos7.0 and it is on drive d, then himem.sys and emm386.exe are in d:\windows. The other dos files are in d:\windows\command. If you can’t find where dos is located, then from the root directory, for example c:\, run the command “dir himem.sys/s” to look for it. Writing autoexec.bat autoexec.bat manages resident programs in the DOS system. The statements in it can actually be run manually one by one, but programs that must be run every time at startup can be made to run automatically through this file. Common statements are: PATH (specify path) SET (set variables) prompt (command prompt) lh (load program into upper memory) MSCDEX (CD driver) smartdrv (hard disk acceleration program) rem (comment) Example explanations: 1,PATH=c:\WINDOWS;C:\WINDOWS\COMMAND;d:\DOS;d:\tools Specify the command search path to make it easier to call programs. Suppose you are in the e:\game directory, then you can directly run the format command located in c:\dos. If you do not specify path, you must be in the c:\dos directory to run this command. 2,prompt $p$g The command line will show where you are, such as c:\dos,e:\fpe,f:\game\san2, etc. If you do not load this command, then no matter what directory you are in, only the drive letter will be shown, such as c:\,e:\,f:\。 This prompt has many other options too; study them yourself in detail. 3,lh C:\dos\mouse.com Load the mouse driver mouse.com into upper memory. Many DOS games need mouse support. If you do not load the mouse driver statement, you will not be able to use the mouse. 4,doskey After loading it can record your keyboard command history, so you do not have to repeatedly type cumbersome commands you have used before. Use the up and down arrow keys to select from the history. 5,the set command, for setting environment variables, has many forms, for example set temp=f:\temp Specify the DOS temporary directory as f:\temp, on the condition that you have drive f and that the temp directory exists. DOS’s default temp directory is c:\dos, but I suggest using an empty directory. Because after using dos for a long time, a lot of junk will accumulate, just like in windows, and it will all go into the temp directory. As long as there are files in it, they are junk and can be deleted. But the default dos directory contains many system files, and people unfamiliar with it may not be able to tell which are junk and which are system files. set tmp=f:\temp Specify the windows temporary directory as f:\temp; the rest is the same as above. SET BLASTER=A240 I10 D3 H7 P330 T6 Set sound card variables such as volume, channels, ports, etc., as set by the installer. set path=c:\dos Simplified as path= ,see above set dircmd=$1/og/p Set the dir variable 6, lh C:\WINDOWS\COMMAND\MSCDEX.EXE /s /D:MSCD001 /V /m:20 Load the CD driver into upper memory. This is usually done by the installer. 7, c:\dos\smartdrv c+ d+ e+ Start the hard disk/CD acceleration program to speed up reading and writing; c+ d+ e+ etc. specify cache for drives c: d: e:. Summary of the autoexec settings usually needed for DOS games: PATH C:\WINDOWS;C:\WINDOWS\COMMAND;c:\DOS; prompt $p$g lh C:\WINDOWS\COMMAND\doskey lh c:\windows\command\mouse.com set variables depend on the specific situation If you also need a sound card to play, you may also need to load the sound card startup program, for example C:\PROGRA~1\CREATIVE\SBLIVE\DOSDRV\SBEINIT.COM, which is usually done by the installer. Note: the c:\windows\command mentioned in this article is the default dos directory for dos7.0. If yours is dos6.0 and it is on drive d, then the dos files are in d:\dos. The mouse.com file is not part of the default dos setup; you need to get it through other means. With these two files configured, after each startup you can use the mem command to check whether your base memory is large enough. Usage: mem/c/p. Look at the base memory section. Generally speaking, 550K is enough to run most DOS games. If it is not enough, then free some less important resident programs, such as doskey, restart, and adjust it little by little...(dos really is that annoying) Other game issues Some programs require support from special display card programs, such as dos4gw, ega, svga, etc., and some need a large amount of video memory to run. Modern graphics cards basically no longer have the problem of insufficient video memory, but it is possible that advanced graphics cards have eliminated old display modes, and some game happens to use exactly those modes. Unless you replace it with an old graphics card, otherwise you simply can’t play that game. For example, many advanced PCs cannot play Romance of the Three Kingdoms V. The reason is that both the graphics card mode and the sound card mode are too old, and new graphics cards cannot implement them. So I myself can’t relive it either. There is also the first Romance of the Three Kingdoms; on some graphics cards it will black out periodically during play, and that is also a conflict problem. If the program requires sound card support, then you need to install DOS sound card drivers; some games come with a general sound card installation program, and generally speaking choosing the sound blaster series is enough. Some motherboard-integrated sound cards only provide windows drivers and no dos drivers, so you may not have music when playing games. If the game needs to use a CD-ROM drive, then you need to install a CD-ROM driver. If you cannot find a suitable CD-ROM driver, you can use the universal CD-ROM driver that comes with win98; it is included when making the installation disk. If it is a CD version of a game, you can use fakecd(cdx) to emulate a CD, for example: first extract the game into a directory, such as d:\sanguo, then run cdx d:\sanguo /L:z(specify drive z as the virtual CD for sanguo). For details please see the instructions in cdx/? If the game requires mouse support, you need to install a mouse driver. Common ones are mouse.com,qmouse.com,gmouse,mmouse, etc. If the game runs too fast, you can use game speed adjustment software such as fpe to adjust it. The computer clock frequency when old games were designed was far slower than today’s P4, and many old DOS games run astonishingly fast. If you do not slow them down, many things simply can’t be played; you are no match for the computer at all. Related DOS game software gb5 ,gamebuster 5.0 , Game Buster, an early game hacking tool. It has a fuzzy search function, can save game progress, and can adjust game speed. Its drawback is that it does not support graphical dos4gw interface systems such as koei’s. Press TAB twice to activate the interface. It is inconvenient to use, and input has to be converted into hexadecimal. fpe,The Whole-Trick Expert, is better than gb. It supports the dos4gw interface, supports fuzzy search (this function was removed in the windows version, unfortunately), cannot save progress, is activated by pressing *, and supports decimal input. It is much faster than gb and is recommended. getcap, game screenshot tool. Press shift to capture and save as gif format. It is fairly easy to use. Its drawback is that it is not very universal; some games with special interface systems cannot be captured. diskedit, the file modification tool from Norton Utilities, can modify game saves. The specific usage will not be described in detail. Supplement: I. About Game Buster GB, I think it also has points better than FPE, mainly two functions that FPE does not have: 1, It can save the current memory image. This function can mainly be used to save progress in some games that do not have a save feature. In addition, this function can also be used for some games that require a code sheet or the like to be entered at startup, so you don’t have to look through the code sheet every time. This function is not even limited to games. In the past, some DOS application software had to read a protected disk; after the protected disk had been read, you could use GB to save the memory image, so afterward there was no need to read the disk again. But its limitation is that the DOS boot configuration must be the same; if it is different, it will not work. 2,GB has a tracing function. After finding the memory location of HP or life value, GB can trace and monitor this address. Once the program modifies this address, GB will automatically pop up a menu and display in red the machine code of the few instructions currently modifying the monitored memory address. Then those instructions can be automatically canceled, and your game becomes an invincible version. In addition, if you write down the few machine-code instructions shown in red (it is best to also note a few adjacent machine codes), then use a tool such as PCTOOLS under DOS to find and modify the corresponding instructions in the game program, you can even make an invincible version of the game that can run on its own without GB. This function is also very practical. II. As for game tools, there is another very good tool that should not be missed, namely GAMETOOL. Actually, calling it a game tool is really understating it. In the DOS era it could almost stand comparison with SOFTICE. It has a powerful built-in DEBUGER, more than enough for tracing and cracking application software, let alone games. Even so, GAMETOOL’s game modification functions are also very powerful and convenient. It can be used as FPE, with convenience no worse than FPE, and it can also be used as an advanced debugging tool like SOFTICE. It is a tool suitable both for experts and for beginners. -------------------------------------------------------------------------------- The explanations used in this article are based on the dos6.22 system. If you need to further understand dos commands, please see help.com in the dos directory. |
|
| Floor2 kind-uo | Posted 2003-06-17 00:00 |
| 初级用户 Posts 22 Credits 199 | |
|
OP
A question for you: when I play DOS games in WIN98, I find that the system does not have DOS expanded memory. Should I write a DEVICEhigh=C:\dos\EMM386.EXE ram ; and if so, in which file should I write it? Please send me an email. My email: KIND-UO@163.Com I'm a newbie, please be detailed. Thanks! |
|
| Floor3 young1234 | Posted 2003-09-18 00:00 |
| 中级用户 Posts 62 Credits 333 | |
| Floor4 cn_archer | Posted 2003-09-18 00:00 |
| 元老会员 Posts 991 Credits 2,903 From 福建省 | |
|
Good article, sharing it!
|
|
| Floor5 young1234 | Posted 2003-09-24 00:00 |
| 中级用户 Posts 62 Credits 333 | |
| Floor6 DOCO | Posted 2003-09-26 00:00 |
| 初级用户 Posts 6 Credits 133 | |
|
Good post
|
|
| Floor7 ddvcc | Posted 2004-09-12 00:00 |
| 初级用户 Posts 7 Credits 114 | |
|
Good article, DOS is almost completely forgotten now
|
|
| Floor8 mantis | Posted 2005-01-27 00:00 |
| 初级用户 Posts 1 Credits 102 | |
|
Well written. Supporting it.
|
|
| Floor9 studenting | Posted 2005-02-02 00:00 |
| 新手上路 Posts 4 Credits 9 | |
|
Hard indeed, studying diligently
|
|
| Floor10 merlin | Posted 2005-02-11 00:00 |
| 初级用户 Posts 18 Credits 143 | |
|
Bump
|
|
| Floor11 ttimber | Posted 2005-03-29 00:00 |
| 初级用户 Posts 43 Credits 198 | |
|
Good article, sharing it!
|
|
| Floor12 wangfangjian | Posted 2009-04-08 12:08 |
| 中级用户 Posts 192 Credits 274 | |
|
Bump
|
|
| Floor13 jzwspace | Posted 2009-08-13 23:47 |
| 初级用户 Posts 17 Credits 34 | |
|
Bump
|
|
| Floor14 kongdewei | Posted 2021-10-01 17:21 |
| 新手上路 Posts 3 Credits 6 | |
|
Thanks for sharing
|
|
| Floor15 jshan888 | Posted 2022-05-22 21:32 |
| 初级用户 Posts 26 Credits 51 | |
|
Learned something, lots of classic old knowledge,
|
|
|
[ Contact the Union admin team -
中国DOS联盟 -
Standard version ] Sponsored by ifanr Inc | © 2001–2023 |