home *** CD-ROM | disk | FTP | other *** search
/ Emulator Universe CD / emulatoruniversecd1998.iso / NES / Emus / NESticle / README.TXT < prev   
Encoding:
Text File  |  1997-09-09  |  21.3 KB  |  560 lines

  1. =================================================================
  2.  NESticle                                   Version 0.41 (08/26/97)
  3.  by Bloodlust Software
  4. =================================================================
  5.  
  6. Death to the defiler.
  7.  
  8. Do not send any files without asking first.
  9.  
  10. Do not ask about SNESticle (or anything else you want emulated).
  11.  
  12. None of the 'extended' mappers (>15) are supported in NESticle,
  13. and chances are they wont be anytime soon.
  14.  
  15. Two scroll fix options alter the way that nametable writes
  16. are interpreted. This can fix or break some games. I can't figure
  17. out how scrolling is supposed to work in all cases, so
  18. these 'workaround' options were put in to fix a few games.
  19.  
  20. Having the PCM channel enabled will cause static in most games.
  21.  
  22. If you get a corrupt volfile error: -disablelfn 
  23.  
  24. For increased compatibility with all monitors, the default DOS
  25. resolution is 320x200. This means that the bottom 24 lines of
  26. games are cut off unless you switch another resolution (such as
  27. 256x224, 256x256, 320x240 etc).
  28.  
  29. ---------------------
  30.      What it is
  31. ---------------------
  32.  
  33. NESticle is a DOS/Win95 based emulator for the Nintendo
  34. Entertainment System written in C++/Assembly.
  35.  
  36. It is freeware and it is not to be distributed with game
  37. ROMs and it is not to be modified or sold.
  38.  
  39. A majority of the NES technical information used to create this
  40. came from Marat Fayzullin's (fms@freeflight.com) great NES.DOC.
  41.  
  42. Sound information was provided by Y0SHi (yoshi@parodius.com) from
  43. his NES technical document.
  44.  
  45. ---------------------
  46.      Revisions
  47. ---------------------
  48.  
  49. Version 0.41:
  50.  - '-nothrottle' command line option
  51.  - 6502 speedups
  52.  - Correct sprite priorities (SMB3/PO)
  53.  - Corrected trapbadops
  54.  - Fixed vram corruption on reset
  55.  
  56. Version 0.40:
  57.  - Scroll fix workarounds
  58.  - Fixed soft-resets
  59.  - Rom directory saved
  60.  - Automatic state backuping
  61.  - "Perfect" sound constant
  62.  - Partial grungy PCM channel (only a few games) disabled by default
  63.  - State display
  64.  - Mapper #6 mirroring fix
  65.  - Scanlines in mode 256x256
  66.  - 256x224 made more compatible
  67.  - Completely rewritten 6502 CPU core
  68.  - Added RDTSC and FPUcopy for pentiums
  69.  - Added support for MMC1 ROMs >256k
  70.  - Speed throttle disabling
  71.  - Improved waitvsync
  72.  - GUI enhancement
  73.  - Fixed MMC1 glitch
  74.  - '-nomsgpopup' option added
  75.  - Default DOS res set to 320,200
  76.  - Changed DOS SB sound driver
  77.  - Fixed DOS hardware error handler bug
  78.  - Fixed crash bug with too long descriptions in rom patch files
  79.  
  80. ---------------------
  81.     What it does
  82. ---------------------
  83.  
  84. NESticle emulates the basic NES hardware, along with several of
  85. the memory mapping chips used by various games. 
  86.  
  87. What's emulated:
  88.  
  89.    -6502 CPU
  90.    -PPU
  91.    -VRAM/VROM
  92.    -Horizontal/Vertical mirroring
  93.    -Scrolling
  94.    -8x8 and 8x16 Sprites
  95.    -Dual joypads
  96.    -iNES Memory mappers 0,1,2,3,4  (5,6,7,8,9,11,15 partial)
  97.    -Battery backed RAM
  98.    -Sound emulation
  99.  
  100. Other neat features:
  101.  
  102.    -Multiple save states
  103.    -Joystick/"GrIP" support
  104.    -Network play (Win95 exe only)
  105.    -"Friendly" GUI
  106.    -VESA/DirectDraw support
  107.    -Fullscreen 256x224 VGA mode (DOS only)
  108.    -Save .pcx snapshots
  109.    -Editable pattern tables (CHR/tile/vrom)
  110.    -iNES single file cart format
  111.    -Wave output loggable
  112.    -Editable palette (I dont have the correct colors)
  113.  
  114.  
  115. ---------------------
  116.  What it doesn't do
  117. ---------------------
  118.  
  119. Full PCM channel.
  120.  
  121. GUS support is buggy.
  122.  
  123. ---------------------
  124.   What you get
  125. ---------------------
  126.  
  127.   NESticle.exe     : The 32-bit DOS version
  128.   NEStcl95.exe     : The Win95/NT Directdraw version
  129.   NESticle.pal     : The NES palette (256 colors in RGB format)
  130.   gui.vol          : Extra graphics stuff for the gui
  131.   readme.txt       : This file
  132.  
  133. Note that it does not come with ROMs.
  134. It will never come with ROMs.
  135. And it must never be distributed with ROMs.
  136. Distribute it with ROMs and you die.
  137. Ask me for ROMs and you die.
  138.  
  139.  
  140. ---------------------
  141.   What you need
  142. ---------------------
  143.  
  144. A 486 or Pentium running DOS or Windows 95/NT.
  145.  
  146. The DOS version requires DOS4GW, available separately.
  147.  
  148. For the Windows version you MUST HAVE DirectX Version 3.0.
  149. It's available somewhere on Microsoft's labyrinth of a website.
  150. At least 16MB of memory for the Win95 version.
  151.  
  152. NESticle can take advantage of VESA 2.0 support if it exists.
  153. If it does not exist, NESticle will resort to only the
  154. video modes 320x200, 256x224, 256x240, 256x256.
  155. You need about 8MB of memory for the DOS version.
  156.  
  157. The DOS version currently supports 8-bit or 16-bit Soundblasters
  158. or compatible, or the Gravis Ultrasound. 16-bit preferred, of course.
  159. The Win95 version utilizes DirectSound for digital output.
  160.  
  161. ---------------------
  162.  How to work it
  163. ---------------------
  164.  
  165. Load up a .NES rom from the File/Load ROM.
  166. Reset the rom from CPU/Reset.
  167.  
  168. If you're running in a high-res mode (>320x240), the NES
  169. game screen will appear in a window. You can maximize the window
  170. with the "SQUARE" button in the title bar. You close the window with
  171. the X button.
  172.  
  173. You can toggle the GUI on and off by pressing ESC.
  174.  
  175. You change the input devices from the Settings/RedefineInput menu(s).
  176. No matter what the settings are, Enter/Tab are always Start/Select in order
  177. to accomodate 2 button joysticks. Enter/Tab only work if the game window
  178. has input focus (click on it) or the gui is disabled.
  179.  
  180. F5/F7 saves and loads your games. Essentially it stores the entire NES state
  181. in a state file. Pressing the keyboard keys 0-9 (not the numeric keypad ones)
  182. will change the current state slot for subsequent saves/loads:
  183.    0 = "xxxx.STA"        (xxxx is the rom file name)
  184.    1 = "xxxx.ST1"
  185.    2 = "xxxx.ST2"
  186.      ... etc
  187. The default slot whenever a rom is loaded is 0 (ie "xxxx.STA")
  188. With statebackuping on, when saving, the old state file is renamed to 
  189. 'xxxx.bak'. You'll have to manually rename the backup state file to
  190. use it again.
  191.  
  192. You can record movies with CPU/NES Movie/Record. This will create
  193. a NES Movie file (*.nsm) which contains the NES state along with
  194. recorded input so you can send them to your friends and bore them
  195. to death. CPU/NES Movie/Stop will stop the recording.
  196. Recording takes 2 bytes/frame, 120 bytes/second, 7K/minute,
  197. and 432K per hour (10MB per day). When playing a movie, be sure
  198. the correct ROM is loaded or else things'll get weird. Once the
  199. movie is done playing NES control is relinquished.
  200. One thing to beware, movies recorded with NESticle will not
  201. be compatible with future versions if the emulation core changes.
  202.  
  203. The NSM files are backward compatible with STA files, in other
  204. words, renaming zelda.nsm to zelda.sta will allow you to load the
  205. movie as a normal state file and play from the movie's beginning point.
  206. Additionally, STA files are backward compatible with SAV files,
  207. renaming zelda.sta to zelda.sav will load it as battery backed mem.
  208.  
  209. To edit patterns, View/Pattern tables, then click on a pattern and edit it.
  210. Right clicking on a pattern will change its attribute (palette), to aid
  211. in drawing. If you wish, you can save the changes with File/Write VROM, and the
  212. VROM will be written directly to the .NES file, so beware.
  213.  
  214.  
  215. ---------------------
  216.   ROMS and stuff
  217. ---------------------
  218.  
  219. NESticle currently uses the iNES single file cart format (*.NES).
  220. It will support the pasowing format in the future.
  221. The ROMs must be stored in the same dir as the .exe.
  222.  
  223. Here's a description of a sample cart 'ZELDA' and some possible extensions:
  224.  
  225.  - ZELDA.NES
  226.     The actual ROM/VROM data preceded by a 16-byte header
  227.  
  228.  - ZELDA.HDR
  229.     An alternate 16-byte header file. If NESticle encounters this in the dir
  230.     of the ROM, it will use this header instead of the one present in the
  231.     NES file.
  232.  
  233.  - ZELDA.SAV
  234.     8K file representing the contents of the battery backed memory used
  235.     in some games. This file is automagically saved and loaded as needed.
  236.  
  237.  - ZELDA.ST?
  238.     It's the 'state' file used by saved games.
  239.  
  240.  - ZELDA.NSM
  241.     Recorded NES Movie.
  242.  
  243.  - ZELDA.PAT
  244.     Text file containing ROM patches
  245.  
  246.  
  247. Numerous roms floating around out there have incorrect headers.
  248. Having an incorrect memory mapper type in the header will most likely cause
  249. the game to crash. Having an incorrect mirroring bit will cause the background
  250. to appear jumbled, or split, while scrolling. You can flip the mirroring bit
  251. from the settings menu. If changing the mirroring fixes the game, you can then
  252. write the ROM header as described above.
  253.  
  254.  
  255. ---------------------
  256.    ROM patching
  257. ---------------------
  258.  
  259. I finally deciphered GameGenie codes with some basic info provided
  260. by Benzene of Digital Emutations (demu@wspice.com). No thanks to Galoob.
  261.  
  262. NESticle supports GameGenie codes and general patching of the
  263. CPU ROM address space ($8000-$FFFF).
  264.  
  265. Bring up the ROM patching dialog with F6 or from the CPU menu.
  266. There are two edit fields in the dialog, the Name and the Code.
  267. The Code field is where the actual code goes (eg APZLGG). 
  268. The Name field lets you type in a description of the code (eg Megajump),
  269. if no name is entered then the code string is used as the name.
  270. Once you've filled these in, clicking "Add" (or pressing enter) will 
  271. add it to the list of patches. To activate or deactivate the patch, 
  272. doubleclick on the code name in the listbox or click on "Toggle".
  273. "Remove" deletes the patch completely. "Save" writes all the patches
  274. to the text file <romname>.pat, this file is decribed below.
  275.  
  276. NESticle accepts either GameGenie codes or raw patches.
  277. GameGenie codes can be either 6 or 8 digits and
  278. use the letters:
  279.     A P Z L G I T Y   E O X U K S V N
  280. Deciphering the GameGenie code is a mess and I won't
  281. go into it here. NESticle internally converts them to a raw format.
  282.  
  283. The raw patches have two formats that coorespond to both
  284. types of Game Genie codes:
  285.  
  286.         <$addr>:<$val>          (6 letter GG code)
  287.         <$addr>?<$key>:<$val>   (8 letter GG code)
  288.  
  289. <$addr> is a 15-bit hex address within $8000-$FFFF of 
  290.           the CPU address space (the rom area).
  291. <$val> is the 8-bit hex value to be patched at that address.
  292. <$key> is an 8-bit hex number that MUST be present at that
  293.           ROM location before the patch will be active.
  294.  
  295. Examples:
  296.  10A4:10    patches CPU address $90A4 with the hex value $10.
  297.  05A1?5B:FF patches CPU address $85A1 with the hex value $FF if 
  298.              and only if $85A1 currently contains $5B
  299.  
  300. NESticle can save a .pat file that contains all the patches
  301. created during a game. This file can be modified using a
  302. text editor. Each line of the .pat file looks like this:
  303.  
  304.           [+]<code> [<name>]
  305.  
  306. [+]    if a '+' is prefixed to the code, then it will be automatically
  307.         activated when the game is run
  308. <code> is the patch itself (GG 6/8 or raw format).
  309. <name> is the text description of the code, if no name is supplied
  310.         then the code is used as the name
  311.  
  312. Note: If more than one patch modifies the same address (and have compatible
  313. keys) then only one can be active at once. Activating one will deactivate
  314. the others (ie they are mutually exclusive).
  315.  
  316.  
  317.  
  318. ---------------------
  319.    Input Devices
  320. ---------------------
  321.  
  322. NESticle supports analog joysticks, 4-button gamepads,
  323. the Gravis GrIP gameport and keyboard input.
  324.  
  325. Some general things:
  326.  - There are two input devices, one each for NES controller 1 and 2.
  327.  - Change the input devices with Settings/RedefineInput
  328.  - Enter/Tab will simulate Start/Select on NES controller 1, ONLY when
  329.     the GUI is disabled or the NES game window has input focus (click on it)
  330.  - You can remap the buttons for a joystick input device with the 
  331.     command line option '-remapbut' or from the "Remap buttons" dialog...
  332.     Simply click on the NES button type and then press the joystick button 
  333.     you wish to use. Pressing any key will set the NES button to "None".
  334.  - You can redefine the keys for a Keyboard input device with the 
  335.     Redefine Keys dialog, or with the '-setkey' command line option
  336.  
  337. Under DOS:
  338.  - Joystick 1 or 2 refer to 2-button analog joysticks only!
  339.  - "Gamepad" refers to a 4-button analog joypad (or joystick)
  340.    The default button mapping for "Gamepad" conforms to that
  341.    for a Gravis Gamepad (ie, 0 2 1 3), but can be changed
  342.  - Due to hardware limits, only one 4-button device can be connected
  343.  - You can interactively calibrate the joystick with the "Calibrate" 
  344.    button. Just center and swirl. The joystick thresholds can be also
  345.    set with the '-joythresh' command line option.
  346.  - In order to enable GrIP support, you MUST copy the "grip.gll" file
  347.     to NESticle's startup directory. NESticle will load the driver
  348.     if it finds it and the GrIP devices in slot 1 or 2 can be used.
  349.  
  350. Under Win95:
  351.  - Joystick 1 and 2 refer to joystick device 1 and 2 as defined under
  352.     Win95's Control Panel/Joystick and can be calibrated from there
  353.  - Gamepad refers to joystick device 1 (with the default Gravis Gamepad mapping)
  354.  - Under Win95 there is no practical limit to the number of buttons
  355.     per joystick device, and any can be remapped
  356.  
  357. GrIP support was added via Gravis's SDK, however it doesn't seem to 
  358. work with other devices besides the GrIP Gameport. I dont know why.
  359.  
  360. ---------------------
  361. Command line options
  362. ---------------------
  363.  
  364. DOS & WIN95:
  365. ------------
  366.  
  367. @<filename>     : Parses the file <filename> for command line options
  368.  
  369. -res <xw> <yw>  : Sets the resolution to xw,yw on startup.
  370.                 : Use this if 256x224 doesn't work or you get a
  371.                 : "Unable to init DDraw: invalid mode" error
  372.  
  373. -setinput <num> <type>
  374.                 : Sets input device <num> to <type>
  375.                    ex. '-setinput 1 GRAVIS'
  376. -remapbut <device> <b> <a> <sel> <start>
  377.                 : Remaps buttons for <device>
  378.                 : <device> can be JOY1, JOY2 or GRAVIS
  379.                 : <b>,<a>,<sel>,<start> are the joystick button #'s for each NES button
  380.                 : A setting of '255' will disable the NES button
  381.                 : The old 'swapbut' is now obselete, instead use "-remapbut JOY1 1 0"
  382. -setkey <device> <ul> <u> <ur> <l> <r> <dl> <d> <dr> <b> <a> <sel> <start>
  383.                 : Sets the keyboard scancodes for <device>
  384.                 : <device> can be KEY1 or KEY2
  385. -setjoythresh <num>  <left> <right> <up> <down>
  386.                 : Sets the joystick threshold for analog joystick <num>
  387.                 : left,right,up,down define the joystick's "dead-zone"
  388.  
  389. -waitvsync      : Wait for the vertical sync to draw frames (see Performance)
  390. -hidegui        : Hide GUI on startup
  391. -nomsgpopup     : Disables the last message from popping up on screen
  392.  
  393. -load <rom>     : Load <rom>
  394. -run <rom>      : Load & Run <rom>
  395. -restore <rom>  : Load & Run & Restore state for <rom>
  396.  
  397. -sndrate <rate> : Sets the sound sampling rate (8000-44100) default=22050
  398. -sndblksize <s> : Sets the size of the mixing block (in samples) default=256
  399. -nosound        : Bypasses the initialization of any sound hardware
  400. -force8bit      : Forces 8-bit sound output (even if 16-bit exists)
  401.  
  402. -romdir <dir>   : Sets the startup dir for .NES roms
  403. -savedir <dir>  : Sets the directory for .SAV and .STA files
  404. -pcxdir <dir>   : Sets the directory for saving snapshots
  405. -logdir <dir>   : Sets the directory for logging and debug files
  406. -patchdir <dir> : Sets the directory for .PAT files
  407.  
  408. DOS only:
  409. ---------
  410. -? or -h        : Display command line help
  411. -disablelfn     : Disables long file name support
  412. -novesa         : Don't use VESA extensions
  413. -linear         : Force linear video mode
  414. -banked         : Force banked video mode
  415.  
  416. -sb   <port> <irq> <dma8>  : Forces 8-bit soundblaster settings (ex -sb 220 7 1)
  417. -sb16 <port> <irq> <dma16> : Forces 16-bit soundblaster settings (ex -sb16 220 5 5)
  418.       (if soundblaster settings are not supplied, they will
  419.         be extracted from the BLASTER environment variable,
  420.        GUS settings are extracted from the ULTRASND variable)
  421.  
  422. -rdtsc          : Enable the use of the Pentium RDTSC profiling instruction
  423. -fpucopy        : Use the FPU for mem->vidmem copies (pentium only)
  424.  
  425.  
  426. "NESticle.ini" and "NEStcl95.ini" are two automatically generated
  427. configuration files which are parsed before the command line
  428. itself. You can manually edit the constants in this file if
  429. you wish, but any additional commands or options added to it
  430. will be overwritten the next time you run NESticle.
  431.  
  432. The two files "NESticle.cmd" and "NEStcl95.cmd" are user-editable
  433. files for command line options and will be appended to the
  434. ini files when they are parsed.
  435.  
  436.  
  437. ---------------------
  438.      Netplay
  439. ---------------------
  440.  
  441. Netplay at this point is very preliminary.
  442. It is still quite buggy.
  443.  
  444. Netplay is only available with the Win95 version (using Winsock),
  445. over either the TCP/IP or the IPX protocols.
  446. In the future, the DOS version may support the IPX protocol.
  447.  
  448. One person must start a server (Net/Start server) and select
  449. a protocol to use as well as the port. The person's name
  450. must be entered as well. The opponent must connect to this
  451. server (Net/Connect), and for the TCP/IP protocol he must
  452. supply the server's IP address. Only one person can be
  453. connected to a server at once. Do not try to run more than 
  454. one NESticle server on the same port on the same
  455. network, the results will be unpredictable.
  456.  
  457. After the connection has been made, the connection status 
  458. window may be closed and the connection will remain active. 
  459. Select Net/Disconnect to close the connection.
  460. You can chat with the other player by opening the chat
  461. window with Net/Chatwindow.
  462.  
  463. After you are connected, one person can load up a ROM, and
  464. if the remote player also has the ROM his/her side will
  465. load it as well. If the remote player does not have the
  466. ROM or has an incompatible ROM (ie wrong size) then the
  467. game will abort and an error will appear in the message window.
  468. The person who last loaded the ROM or last reset the ROM
  469. will be player 1. The game is played using each computer's 
  470. input device 1.
  471.  
  472. Now for the complex stuff:
  473. In order for netplay to work at all, both sides need
  474. to be syncronized at all times. This is no problem for a low
  475. latency LAN running over ethernet for example. However this
  476. spells trouble for internet connections. In the connection window,
  477. the ping times of all the nodes are shown. The ping time number
  478. is measured in virtual frames. The NES normally runs at 60 frames
  479. per second, so a ping time of '30' would be about 500ms. The
  480. lower the ping time the better. The bandwidth that NESticle uses 
  481. is negligable, less than 100bytes/sec.
  482.  
  483. Anyway, adjusting the 'vframe latency' number will affect how
  484. lagged each player's input is. It essentially controls
  485. how often game update packets are sent.....
  486. A low vframe latency number will result in a very responsive game
  487. if your network can handle it. A high vframe latency
  488. setting will result in a 'lagged game', but it may be necessary
  489. for high latency connections (such as the internet).
  490. If you have your vframe latency set too low, you will notice that the
  491. game will 'freeze' periodically as it waits for the other computer
  492. to respond. If you have it set too high, your game input will be
  493. severely lagged, but the game will not 'freeze'.
  494.  
  495. The default setting is 5, I highly recommend changing it.
  496. On a LAN, where the connections are fast and reliable, a vframe
  497. latency of about 2 will result in great gameplay and performance.
  498. On the internet, the best setting is about half of your pingtime.
  499. I left the setting adjustable so you can mess with it to see whats
  500. best. As far as internet play goes, personally i don't think
  501. it runs very well, but that's not my fault as much as it is the
  502. internet's and there's nothing I can do about it.
  503.  
  504. Some last things: the vframe latency setting is not adjustable
  505. while in the middle of a game. You must free the ROM, change it,
  506. then reload. Also, save games will not work while connected and
  507. you cannot restore saved states, nor can you apply rom patches.
  508.  
  509.  
  510. ---------------------
  511.      Contact
  512. ---------------------
  513.  
  514. Bloodlust Software
  515. bldlust@parodius.com
  516. http://nesticle.parodius.com/
  517.  
  518. Email me about ROMs and your suffering will be legendary.
  519.  
  520. ---------------------
  521.   Acknowledgements
  522. ---------------------
  523.  
  524. Marat Fayzullin for his priceless NES.DOC and iNES emulator.
  525.  
  526. Y0SHi for taking the time to maintain his 'nestech.doc'
  527.  
  528. Y0SHi, Marat and FanWen for supplying valuable information on NES sound.
  529.  
  530. Additional help by Neill Corlett, if you haven't gotten MGE yet
  531. then you suck: http://www4.ncsu.edu/eos/users/n/nscorlet/mge/
  532.  
  533. Additional info:
  534.  FanWen (yangfanw@ms4.hinet.net)
  535.  Andrew Davie (adavie@comcen.com.au)
  536.  Matthew J Richey (mr6v+@andrew.cmu.edu)
  537.  Benzene (demu@wspice.com)
  538.  Neil Bradley (neil@synthcom.com)
  539.  Benny Boola Hill
  540.  DeceiverX, Loopy, Vectriff, Zophar
  541.  
  542. Scrotum-art and testing by digger.
  543.  
  544.  
  545. ---------------------
  546.      Disclaimer
  547. ---------------------
  548.  
  549. NESticle Copyright 1997 Bloodlust Software
  550. Nintendo Entertainment System (NES) is a registered trademark of Nintendo.
  551. Game Genie is a trademark of Galoob.
  552. Neither Bloodlust Software nor the author are affiliated with Nintendo
  553.  nor advocate the piracy of NES games.
  554. NESticle is freeware and can be distributed freely as long as it is not
  555.  modified and ROMs are not packaged with the program.
  556. When you use this software you do so at your own risk. The author is 
  557.  not responsible for any loss or damage resulting from the use or 
  558.  misuse of this software.
  559. If you do not agree with these terms then NESticle is not for you.
  560.