Alternate A and B is for a specific case where both the A and B autofire buttons are pressed simultaneously. With alternate A and B, the fire pattern will be A,B,A,B rather than A+B, off, A+B, off.
-
Note: All autofire patterns read the Lag Counter (see display) and skip over any frames where input is not polled. This means that in a laggy area, the autofire pattern will not be affected.
+
Note: All autofire patterns read the Lag Counter (see display) and skip over any frames where input is not polled. This means that in a laggy area, the autofire pattern will not be affected.
The RAM patches are all applied a short time before the emulated vertical blanking period. This detail shouldn't concern most people, though. However, this does mean that cheating with games that use bank-switched RAM may be problematic. Fortunately, such games are not very common (in relation to the total number of NES and Famicom games).
-
The cheat search comes with its own set of tools for finding addresses in memory to use for making cheats (or for monitoring the addresses in the memory watch window)
+
The cheat search comes with its own set of tools for finding addresses in memory to use for making cheats (or for monitoring the addresses in the memory watch window)
Cheat Files
@@ -208,7 +208,7 @@
Note: When a game is loaded, FCEUX will load any accompanying saved .cht file automatically.
All addresses listed in the cheat search windows are in unsigned 16-bit hexadecimal format and all values in these windows are in an unsigned 8-bit decimal format(the range for values is 0 through 255).
-
Active Cheats
+
Active Cheats
The Active cheats window on the left contains the list of cheats for the currently loaded game. Existing cheats can be selected, edited, and updated using the "Update" button.
@@ -239,14 +239,14 @@
To create a new cheat, you have to find an address, for this use the cheat search portion of the window.
-
Cheat Search
+
Cheat Search
The cheat search is used to find a specific value in the games RAM by process of elimination.
The possibilities window is in the format of Address:Original Value:Current Value
The address is the location in the 6502's address space, the original value is the value that was stored at this address when the search was reset, and the current value is the value that is currently stored at that address. Selecting an item in this list will automatically cause the "Address" field in the cheat information box on the right side of the window to be updated with the selected address.
-
The "Reset" button resets the search process; all valid addresses are displayed in the possibilities window and the data values at those addresses noted in both the left and right columns. The number of possibilities is displayed at the top. Resetting will set it to 2048 or 10240 depending on if the game uses "On cartridge ram" ($6000-$7FFF). (See NES RAM)
+
The "Reset" button resets the search process; all valid addresses are displayed in the possibilities window and the data values at those addresses noted in both the left and right columns. The number of possibilities is displayed at the top. Resetting will set it to 2048 or 10240 depending on if the game uses "On cartridge ram" ($6000-$7FFF). (See NES RAM)
The left column is the "previous value" and the right column is the "current value"
@@ -267,27 +267,27 @@
Any value in the possibilities list can be sent to memory watch by double clicking it.
Highlighting it and hitting the "Add" button under the Active cheats window will automatically activate it as a cheat with the value set to its current value.
-
When you activate a cheat, the item in RAM Search and RAM Watch which corresponding to that address will be marked with a significant color.
+
When you activate a cheat, the item in RAM Search and RAM Watch which corresponding to that address will be marked with a significant color.
-
Example
+
Example
Here is an example of cheat search in action.
Let's say I am playing Mega man 3 and I want to find Mega man's energy level in the game's ram. I will start by opening the ROM and selecting a level. At this point, I know Mega man's energy address is active. So I will pause the game and open the cheat search and hit the reset button. The game uses SRAM so the possibilities window will say 10240 "possibilities".
Next I will frame advance (or briefly unpause) the game. At this point I know Mega man's energy level is still the same as it was. So I click the "equal" button. Next I want to take damage. I know for sure now that the energy level has decreased so after the "ouch" animation, I click the "Less than button". This will cut the possibilities down significantly. Next I will advance some more and click the "Equal" button since I know the value is still the previous value. I will repeat this cycle until I am down to 1 or just a few values. From there I can double click the values to send them to memory watch to monitor them more closely to weed them out. (Note: Mega man's energy is located in $00A2).
-
Context Menu
+
Context Menu
Right-clicking in the active cheats list brings up the context menu.
-
Toggle Cheat - does the same thing as double clicking
+
Toggle Cheat - does the same thing as double clicking
-
Poke cheat value - has a different affect that normal freezing, this makes a one time write of that value as opposed to freezing it temporarily to that value and having it restored later. It has the same affect as typing in values in the Hex Editor.
+
Poke cheat value - has a different affect that normal freezing, this makes a one time write of that value as opposed to freezing it temporarily to that value and having it restored later. It has the same affect as typing in values in the Hex Editor.
-
Goto In Hex Editor - Opens the Hex editor dialog to the position of the selected RAM value.
+
Goto In Hex Editor - Opens the Hex editor dialog to the position of the selected RAM value.
-
Right-clicking in the search result list, you can add the address to memory watch, add cheat or goto in Hex Editor.
+
Right-clicking in the search result list, you can add the address to memory watch, add cheat or goto in Hex Editor.
The Code/Data Logger makes it much easier to reverse-engineer NES ROMs. The basic idea behind it is that a normal NES disassembler cannot distinguish between code (which is executed) and data (which is read). The Code/Data Logger keeps track of what is executed and what is read while the game is played, and then you can save this information into a .cdl file, which is essentially a mask that tells which bytes in the ROM are code and which are data. The file can be used in conjunction with a suitable disassembler to disassemble only the actual game code, resulting in a much cleaner source code where code and data are properly separated.
+
The Code/Data Logger makes it much easier to reverse-engineer NES ROMs. The basic idea behind it is that a normal NES disassembler cannot distinguish between code (which is executed) and data (which is read). The Code/Data Logger keeps track of what is executed and what is read while the game is played, and then you can save this information into a .cdl file, which is essentially a mask that tells which bytes in the ROM are code and which are data. The file can be used in conjunction with a suitable disassembler to disassemble only the actual game code, resulting in a much cleaner source code where code and data are properly separated.
Using the Code/Data Logger
The Code/Data Logger keeps track of every byte in the ROM and records whether it's code (is executed) or data (is read).
You can combine this logging feature with other tools to make them much more powerful:
-
combine with Debugger to see which branches of the game code were executed and which weren't yet
-
combine with Trace Logger to let it log the code selectively
-
combine with PPU Viewer to let it only display graphics that was drawn on screen at least once
-
combine with Hex Editor to enable smart coloring of bytes (so you can observe which bytes are used by the game and how/when they are used)
+
combine with Debugger to see which branches of the game code were executed and which weren't yet
+
combine with Trace Logger to let it log the code selectively
+
combine with PPU Viewer to let it only display graphics that was drawn on screen at least once
+
combine with Hex Editor to enable smart coloring of bytes (so you can observe which bytes are used by the game and how/when they are used)
combine with (an external) Tile Viewer to see which graphics was used during certain play session, and which was not
combine with (an external) ROM Corruptor to make it only corrupt data, but not code
combine with (an external) Disassembler to help it separate code from data
@@ -207,22 +207,22 @@
See, it is very useful for finding certain types of data or code branches. It also makes debugging work more visual, since you can always see which lines of the disassembled code were executed and which weren't.
-
Furthermore, while the Code/Data Logger is running, the Hex Editor will color-code ROM bytes depending on whether they were logged as code or data:
+
Furthermore, while the Code/Data Logger is running, the Hex Editor will color-code ROM bytes depending on whether they were logged as code or data:
For PRG ROM:
-
Dark-yellow - the byte is code
-
Blue - the byte is data
-
Cyan - the byte is PCM audio data
-
Green - the byte is both code and data
+
Dark-yellow - the byte is code
+
Blue - the byte is data
+
Cyan - the byte is PCM audio data
+
Green - the byte is both code and data
For CHR ROM:
-
Yellow - the byte was rendered
-
Light-blue - the byte was read programmatically
-
Light-green - the byte was both rendered and read programmatically
+
Yellow - the byte was rendered
+
Light-blue - the byte was read programmatically
+
Light-green - the byte was both rendered and read programmatically
The Code/Data Logger can also be used to generate a stripped NES ROM.
"Stripped" NES ROM is a ROM in which everything that was not logged by the Code/Data Logger is removed. It can be useful in many ways, for example, you can view the ROM in an external Hex Editor or a Tile Viewer, and you'll see only the parts that were used while playing. Furthermore, you could use it to create a demo ROM by only playing through the parts you would like others to see.
-
Example of such usage:
+
Example of such usage:
1. Open the Code/Data Logger, and press Start to begin logging.
2. Perform a soft and a hard reset while logging, in order to capture the ROM's startup sequence. If you don't do so, you can distribute a save-state file so they will start from within the game.
3. If the game has Save-RAM (e.g. Zelda), you will need to capture the game's Save-RAM initialization routines; you can try to do so by deleting the game's *.sav file and then perform a soft and hard reset again while logging.
Plays specified ROM (ROM name must always be put last in command line arguments)
-
fceux path\rom.nes (or rom.zip)
+
fceux path\rom.nes (or rom.zip)
-
fceux smb.nes
-
fceux c:\fceux\roms\smb.zip
+
fceux smb.nes
+
fceux c:\fceux\roms\smb.zip
Play Movie File
Plays a specified movie (.fm2) file. A valid ROM must be specified or movie will not be played.
-
fcuex -playmovie path\movie.fm2 romname
+
fcuex -playmovie path\movie.fm2 romname
-
fceux -playmovie smb.fm2 smb.nes
+
fceux -playmovie smb.fm2 smb.nes
Read-only Status
Specifies whether a movie will be in "read-only" or "read & write" mode. (Note: a specified movie is not required to be used in conjunction with this command). 1 specifies read only status, 0 specifies read & write.
Lua is a scripting language. It is used in games like Farcry and World of Warcraft (and many other games and applications!). Even though you can find all kinds of tutorials online, let me help you with the basics.
@@ -202,7 +202,7 @@
When you load the script, the emulator will sort of go into pause mode and hand controls over to Lua (you!). Hence you are responsible for frameadvancing the emulator.
IF YOU DO NOT CALL emu.frameadvance AT THE CYCLE OF THE MAIN LOOP YOU WILL FREEZE THE EMULATOR! There. You have been warned. Don't worry though, you'll make this mistake at least once. Just force-quit the application and try again :)
-
Syntax
+
Syntax
Now then. Just like any other language, Lua has a few quirks you should be aware of.
@@ -305,7 +305,7 @@
For easy reference to the standard libraries look on the bottom half of this page: http://www.lua.org/manual/5.1/
-
Lua in FCEUX
+
Lua in FCEUX
Now then, let's get to the emulator specifics!
@@ -331,7 +331,7 @@
BIT(n); -- returns a number with only bit n set (1)
The emulator specific Lua is equal to the one of snes9x, with some platform specific changes (few buttons, for instance).
The following is a quick reference, you can go to the snes9x reference for more details.
To paint stuff on screen, use the gui table. This contains a few predefined functions to manipulate the main window. For any coordinate, 0,0 is the top-left pixel of the window. You have to prevent out-of-bound errors yourself for now. If a color can be passed on, it is a string. HTML-syntax is supported ("#34053D"), as well as a FEW colors ("red", "green", "blue" ...).
@@ -376,7 +376,7 @@
savestate.load(state); -- load the given savestate
savestate.save(state); -- save the given savestate
Emulator background Color when Graphics Background is disabled
-
gNoBGFillColor
-
-
When you disable the backgrounds (Config > Display > Graphics: GB), the default color is black. You can change that color by modifying this value. By default it is 255 (black).
-
-
-
Debugger
-
-
debuggerFontSize 15
-
-
This value determines the size of the "Courier" font used by Debugger and Trace Logger. By default it is 15.
-
-
-
Hex Editor
-
-
hexeditorFontSize 15
-
-
This value determines the size of the "Courier" font used by Hex Editor. By default it is 15.
-
-
-
HexRowHeightBorder 0
-
-
This value determines the number of pixels between each row of values in the Hex Editor. By default it is 0.
-
-
-
HexBackColorR 255
-
HexBackColorG 255
-
HexBackColorB 255
-
-
HexForeColorR 0
-
HexForeColorG 0
-
HexForeColorB 0
-
-
HexFreezeColorR 0
-
HexFreezeColorG 0
-
HexFreezeColorB 255
-
-
These values allows are the Hex Editor color scheme values (RGB). The background color is 255,255,255 (white) by default. The foreground color (text) is 0,0,0 (black) by default. When an address is frozen it is 0,0,255 (blue) by default.
-
-
-
-
+
gNoBGFillColor
+
+
When you disable the backgrounds (Config > Display > Graphics: GB), the default color is black. You can change that color by modifying this value. By default it is 255 (black).
+
+
+
Debugger
+
+
debuggerFontSize 15
+
+
This value determines the size of the "Courier" font used by Debugger and Trace Logger. By default it is 15.
+
+
+
Hex Editor
+
+
hexeditorFontSize 15
+
+
This value determines the size of the "Courier" font used by Hex Editor. By default it is 15.
+
+
+
HexRowHeightBorder 0
+
+
This value determines the number of pixels between each row of values in the Hex Editor. By default it is 0.
+
+
+
HexBackColorR 255
+
HexBackColorG 255
+
HexBackColorB 255
+
+
HexForeColorR 0
+
HexForeColorG 0
+
HexForeColorB 0
+
+
HexFreezeColorR 0
+
HexFreezeColorG 0
+
HexFreezeColorB 255
+
+
These values allows are the Hex Editor color scheme values (RGB). The background color is 255,255,255 (white) by default. The foreground color (text) is 0,0,0 (black) by default. When an address is frozen it is 0,0,255 (blue) by default.
HINT: When entering the address manually, these convenient strings may be used instead of the hexadecimal memory address:
-
NES special addresses:
+
HINT: When entering the address manually, these convenient strings may be used instead of the hexadecimal memory address:
+
NES special addresses:
-
NMI/VBL - non-maskable interrupt vector (at FFFA)
-
RST - reset vector (at FFFC)
-
IRQ - interrupt vector (at FFFE)
+
NMI/VBL - non-maskable interrupt vector (at FFFA)
+
RST - reset vector (at FFFC)
+
IRQ - interrupt vector (at FFFE)
-
FDS special addresses:
+
FDS special addresses:
-
NMI1 - non-maskable interrupt vector (at DFF6)
-
NMI2 - non-maskable interrupt vector (at DFF8)
-
NMI3 - non-maskable interrupt vector (at DFFA)
-
RST - reset vector (at DFFC)
-
IRQ - interrupt vector (at DFFE)
+
NMI1 - non-maskable interrupt vector (at DFF6)
+
NMI2 - non-maskable interrupt vector (at DFF8)
+
NMI3 - non-maskable interrupt vector (at DFFA)
+
RST - reset vector (at DFFC)
+
IRQ - interrupt vector (at DFFE)
-
NSF special addresses:
+
NSF special addresses:
-
LOAD - NSF LOAD address
-
INIT - NSF INIT address
-
PLAY - NSF PLAY address
+
LOAD - NSF LOAD address
+
INIT - NSF INIT address
+
PLAY - NSF PLAY address
-
+
While execution is broken (emulation is paused), the program counter (PC) can be edited, as well as the three registers A/X/Y, and the status flags. Normally they should be left as-is, but changing them at runtime can be useful for more advanced debugging.
The contents of memory starting at the stack pointer (somewhere in the range $0100-01FF) is displayed in the Stack frame below the A/X/Y registers.
The current PPU memory address, sprite memory address, scanline, and rendering pixel are displayed below the stack and status flags. Examples of Scanline number: -1 means Prerender time, 240 is Idle scanline, 0-239 are visible scanlines, 241-260/310 are VBlank scanlines.
-
To the right from the PPU section there's Cycles counter and Instructions counter that keep counting while the game is running. You can use the information for keeping statistics, for code profiling or writing PPU-synchronized code (e.g. raster effects). You can also make the debugger break automatically based on the counters values. The "Reset counters" button resets both counters to 0. You can also access the counters via Lua.
+
To the right from the PPU section there's Cycles counter and Instructions counter that keep counting while the game is running. You can use the information for keeping statistics, for code profiling or writing PPU-synchronized code (e.g. raster effects). You can also make the debugger break automatically based on the counters values. The "Reset counters" button resets both counters to 0. You can also access the counters via Lua.
Disassembly
@@ -272,8 +272,8 @@
Memory contents are displayed in this form:
-
0F:C0A8:24 1F BIT $001F = #$80
-
bb:mmmm:dd dd dd iiiiiiiiiiiii...
+
0F:C0A8:24 1F BIT $001F = #$80
+
bb:mmmm:dd dd dd iiiiiiiiiiiii...
bb - 16k iNES bank, designates which 16k bank from the iNES file is mapped here. Note that the number may be not the same as the actual hardware bank of the mapper.
@@ -288,8 +288,8 @@
Hovering the mouse over the disassembly will display at the bottom of the window more detailed information about the location of this code in the iNES file.
-
There is narrow column to the left of the Disassembly window. Left clicking on this column will open the Inline Assembler, which allows you to patch the ROM at runtime. Right clicking on this column will open the Hex Editor, which allows you to directly edit the ROM. Middle-clicking on this column will bring up the Game Genie Encoder at that address, so you can easily make Game Genie codes.
-
Also, when Code/Data Logger is running, this small column displays whether the respective line of the disassembled memory was executed ("c") or it was read as Data ("d"), or it wasn't logged yet (empty space). This way you can easily distinguish which branches of the game code were executed and which weren't.
+
There is narrow column to the left of the Disassembly window. Left clicking on this column will open the Inline Assembler, which allows you to patch the ROM at runtime. Right clicking on this column will open the Hex Editor, which allows you to directly edit the ROM. Middle-clicking on this column will bring up the Game Genie Encoder at that address, so you can easily make Game Genie codes.
+
Also, when Code/Data Logger is running, this small column displays whether the respective line of the disassembled memory was executed ("c") or it was read as Data ("d"), or it wasn't logged yet (empty space). This way you can easily distinguish which branches of the game code were executed and which weren't.
Symbolic Debugging
@@ -307,7 +307,7 @@
To delete a label, check the "Delete" checkbox and click OK.
The array size specified in delete mode indicates labels of how many bytes will be deleted. If you select $C000 and set array size to 0xF, all the labels form $C000 to $C00E are deleted.
-
The data for Symbolic Debugging is stored in NL files in the same folder as the ROM. You can edit the files in any text editor (to reload all NL files of the currently active ROM file press the "Reload Symbols" button), but it's more convenient to use right-clicks.
+
The data for Symbolic Debugging is stored in NL files in the same folder as the ROM. You can edit the files in any text editor (to reload all NL files of the currently active ROM file press the "Reload Symbols" button), but it's more convenient to use right-clicks.
You can enable and disable symbolic debugging by clicking the checkbox "Symbolic debug" in the lower right corner. In general, there's no need to disable this feature. If you need to see the actual address which got substituted by a name, you can simply left-click the name and watch its address in the "Seek To" text field. This also works when clicking a name in the Trace Logger window.
@@ -330,13 +330,13 @@
Finally, you can make the debugger break after executing a certain number of instructions or CPU cycles.
-
More advanced breakpoints conditions and full automation may be achieved through Lua script breakpoints. See the Lua reference for more information.
+
More advanced breakpoints conditions and full automation may be achieved through Lua script breakpoints. See the Lua reference for more information.
The parser is very strict. All numbers are hexadecimal. Always prefix a number with # for an immediate value, or $ for a memory address. If a memory address needs to be calculated use $[] with the calculation inside the brackets.
@@ -381,16 +381,16 @@
Example conditions:
Break only if register A is less than value at memory address $0005:
-
A < $0005
+
A < $0005
Break only if the value at the indirect address is not equal to FF:
-
#FF != $[$10+($11*#100)]
+
#FF != $[$10+($11*#100)]
Break only if flag N is clear or A is not equal to 00:
-
(N==#0 || A!=#0)
+
(N==#0 || A!=#0)
Break only when accessing a data from bank 2 (the condiition is relevant when using with Read/Write-type breakpoints):
-
T==#2
+
T==#2
Bookmarks
@@ -414,7 +414,7 @@
If the ".DEB files" checkbox in the lower right corner of the debugger window is checked, the emulator will automatically save debug settings such as breakpoints and bookmarks in a .deb file alongside the NES ROM, and load these settings next time you open the ROM.
-
There is a "Rom Patcher" button that may be used to apply a small patch to a ROM, although Hex Editor is more convenient in general.
+
There is a "Rom Patcher" button that may be used to apply a small patch to a ROM, although Hex Editor is more convenient in general.
The "ROM offsets" option will display ROM offsets instead of CPU addresses in the Disassembly window.
In order to play any Famicom (.fds) game, you will need the FDS BIOS ROM image and it must be named disksys.rom.
-
It must be in the base FCEU directory unless you specified a path to disksys.rom in the Directory Overrides List. FCEUX will not load FDS games without this file.
+
It must be in the base FCEU directory unless you specified a path to disksys.rom in the Directory Overrides List. FCEUX will not load FDS games without this file.
File types
@@ -203,24 +203,24 @@
Writing to disk image
-
If a loaded disk image is written to during emulation, FCEUX will store the modified disk image in the save games directory, which is "sav" under the base directory by default (unless changed under the Directory Overrides List).
+
If a loaded disk image is written to during emulation, FCEUX will store the modified disk image in the save games directory, which is "sav" under the base directory by default (unless changed under the Directory Overrides List).
Eject/Insert Disk
Emulates the ejecting of the current disk or the inserting of a new disk. If a disk image is loaded, this command will eject it. If a disk is ejected, this will insert a new disk.
-
This command can be mapped to a keyboard/joypad button in the Map Hotkeys Menu.
+
This command can be mapped to a keyboard/joypad button in the Map Hotkeys Menu.
Switch Disk Side
When prompted by the game, you can emulate the Switching sides of the FDS disk with the NES -> Switch Disk Side command.
-
This command can be mapped to a keyboard/joypad button in the Map Hotkeys Menu.
+
This command can be mapped to a keyboard/joypad button in the Map Hotkeys Menu.
To switch disk side you first have to eject the disk, and after switching sides you have to insert the disk back.
Many FDS games ask you to switch disk side before you can proceed from the title screen. So you have to do the following:
-
1) choose NES -> Eject/Insert Disk, the message "Disk 0 Side A Ejected" will appear
-
2) choose NES -> Switch Disk Side, the message "Disk 0 Side B Selected" will appear
-
3) choose NES -> Eject/Insert Disk again, the message "Disk 0 Side B Inserted" will appear, and the game will change from title screen to player select screen.
+
1) choose NES -> Eject/Insert Disk, the message "Disk 0 Side A Ejected" will appear
+
2) choose NES -> Switch Disk Side, the message "Disk 0 Side B Selected" will appear
+
3) choose NES -> Eject/Insert Disk again, the message "Disk 0 Side B Inserted" will appear, and the game will change from title screen to player select screen.
In the Game Genie Code Decoder/Encoder window, type the code into the Game Genie Code box and click "Add to Cheat List", which will add it to the Cheat Search cheat list. You can then enable/disable them by double-clicking the code in the box (a * means the code is active).
+
In the Game Genie Code Decoder/Encoder window, type the code into the Game Genie Code box and click "Add to Cheat List", which will add it to the Cheat Search cheat list. You can then enable/disable them by double-clicking the code in the box (a * means the code is active).
Making Game Genie codes permanent
@@ -210,7 +210,7 @@
* know how to use the debugger;
* understand NES PRG-ROM bank switching.
-
Once you've found a part of PRG-ROM you want to change to create a code effect, snap the Debugger (if it's not so already) and find the code's location in the PRG-ROM's address space ($8000-$FFFF) (you'll want the debugger snapped so the game won't swap banks out from under you). Then, using the built-in Hex Editor, view the NES memory and go to the PRG-ROM address you wish to modify, then right-click the byte and choose "Create Game Genie Code at this Address". The Game Genie Code Decoder/Encoder will appear, with the Address and Compare boxes filled in (the Compare box represents the address's original value). Enter the new value into the "Value" box.
+
Once you've found a part of PRG-ROM you want to change to create a code effect, snap the Debugger (if it's not so already) and find the code's location in the PRG-ROM's address space ($8000-$FFFF) (you'll want the debugger snapped so the game won't swap banks out from under you). Then, using the built-in Hex Editor, view the NES memory and go to the PRG-ROM address you wish to modify, then right-click the byte and choose "Create Game Genie Code at this Address". The Game Genie Code Decoder/Encoder will appear, with the Address and Compare boxes filled in (the Compare box represents the address's original value). Enter the new value into the "Value" box.
An alternative way to enter the code is to locate the desired address in the debugger, and then middle-click on it, which will summon the GG Code Decoder/Encoder. Then enter the code as described above.
The most basic function of FCEUX is to play Nintendo Entertainment System (NES) and Famicom Disk System (FDS) games.
-
To play a game, simply open a ROM by selecting "Open" in the File Menu (or press Ctrl+O). (See Game Compatibility for information regarding file types that are compatible with FCEU.)
+
To play a game, simply open a ROM by selecting "Open" in the File Menu (or press Ctrl+O). (See Game Compatibility for information regarding file types that are compatible with FCEU.)
To get set up properly, you may need to configure any of the following:
If you load a state by accident, you can right-click and select "Undo Loadstate" to restore the emulator back to the state it was in before the loadstate. Upon using undo loadstate, a redo loadstate will appear as an option.
-
If you make a savestate, it will overwrite the existing savestate for that slot. You have the option to undo this and restore the previous savestate file by right-clicking and selecting undo savestate. Once you undo, you will have the option to redo savestate to restore the savestate that you made. You can also map a hotkey to this function, by default it's mapped to Ctrl+Z.
+
If you make a savestate, it will overwrite the existing savestate for that slot. You have the option to undo this and restore the previous savestate file by right-clicking and selecting undo savestate. Once you undo, you will have the option to redo savestate to restore the savestate that you made. You can also map a hotkey to this function, by default it's mapped to Ctrl+Z.
This allows you to directly edit all of the NES address space (System Bus - $0000-$FFFF). While you can easily modify RAM, or write directly to registers by typing in data, you cannot modify ROM data ($8000-$FFFF) itself. This is because most mappers have registers which are located in this space; so writing there can trigger mapper operations that may cause the game to crash or glitch if you don't know what you're doing. If you want to edit the ROM itself, right-click on the offset and select "Go here in ROM file"; that will take you directly to where you need to be so you can start editing. You can also freeze RAM by clicking on it with the middle mouse button, or by using the right-click menu. This works by adding it directly to the Cheat List, which you can see from the Cheat Console. Finally, the right-click menu can be used to quickly add a read or write breakpoint to the debugger. When adding a breakpoint to the range of ROM addresses ($8000-$FFFF), the Hex Editor also takes into account the number of the bank in which the byte is located.
+
1. NES MEMORY
+
This allows you to directly edit all of the NES address space (System Bus - $0000-$FFFF). While you can easily modify RAM, or write directly to registers by typing in data, you cannot modify ROM data ($8000-$FFFF) itself. This is because most mappers have registers which are located in this space; so writing there can trigger mapper operations that may cause the game to crash or glitch if you don't know what you're doing. If you want to edit the ROM itself, right-click on the offset and select "Go here in ROM file"; that will take you directly to where you need to be so you can start editing. You can also freeze RAM by clicking on it with the middle mouse button, or by using the right-click menu. This works by adding it directly to the Cheat List, which you can see from the Cheat Console. Finally, the right-click menu can be used to quickly add a read or write breakpoint to the debugger. When adding a breakpoint to the range of ROM addresses ($8000-$FFFF), the Hex Editor also takes into account the number of the bank in which the byte is located.
-
2. PPU MEMORY
+
2. PPU MEMORY
This allows you to directly view and write to PPU memory (VRAM).
-
3. OAM MEMORY
+
3. OAM MEMORY
This allows you to directly view and write to OAM memory (sprite RAM).
-
4. THE ROM FILE
+
4. THE ROM FILE
This allows you to edit the ROM file in real time, i.e. while the game is running. If you make a mistake, press Ctrl+Z or Edit->Undo to undo your change (then load a save-state if the game crashed).
The Hex Editor also has support for table files (*.tbl) to map bytes to text. Each line consists of four characters of the form "xx=y", where "xx" is the hex value, and "y" is the character that that value represents. I have also added an extension to represent the Return key: xx=ret whereby pressing the Return key will enter that value into the ROM. You can copy/paste data or text by selecting it and using Ctrl+C (to copy) and Ctrl+V (to paste). Plus, there is an Edit->Find feature that you can use to search for data. This feature should be fairly intuitive, so I won't bother to explain it.
@@ -221,19 +221,19 @@
The Hex Editor highlights certain bytes with different colors to help you distinguish different data.
Usually all bytes are colored black.
-
Bookmarked RAM addresses are highlighted by green color.
-
Freezed RAM addresses are highlighted by blue color.
-
Modified ROM bytes are highlighted by red color.
-
If you have the Code/Data Logger running, bytes that were logged will be colored:
+
Bookmarked RAM addresses are highlighted by green color.
+
Freezed RAM addresses are highlighted by blue color.
+
Modified ROM bytes are highlighted by red color.
+
If you have the Code/Data Logger running, bytes that were logged will be colored:
For PRG ROM segment:
-
Dark-yellow - the byte is code
-
Blue - the byte is data
-
Cyan - the byte is PCM audio data
-
Green - the byte is both code and data
+
Dark-yellow - the byte is code
+
Blue - the byte is data
+
Cyan - the byte is PCM audio data
+
Green - the byte is both code and data
For CHR ROM segment:
-
Yellow - the byte was rendered
-
Light-blue - the byte was read programmatically
-
Light-green - the byte was both rendered and read programmatically
+
Yellow - the byte was rendered
+
Light-blue - the byte was read programmatically
+
Light-green - the byte was both rendered and read programmatically
As the name describes, this tool parses the iNES header of NES ROM file, which is called iNES header, to a human understandable information. You can change various settings of the ROM, such as Mapper#, CHR RAM Size, PRG RAM Size, mirroring type, region... etc.
+
As the name describes, this tool parses the iNES header of NES ROM file, which is called iNES header, to a human understandable information. You can change various settings of the ROM, such as Mapper#, CHR RAM Size, PRG RAM Size, mirroring type, region... etc.
-
This tool is experimental, and incorrect modification to the header may cause the ROM fail to run or some unpredictable consequences. Use at your own risk.
-
+
This tool is experimental, and incorrect modification to the header may cause the ROM fail to run or some unpredictable consequences. Use at your own risk.
+
About iNES Format
The first 16 bytes of each iNES format file store some important settings of the dumped ROM in binary. When NES Emulator loads the game, it will determine how to simulate based on these settings.
-
The iNES format currently has 2 versions, 1.0 and 2.0.
+
The iNES format currently has 2 versions, 1.0 and 2.0.
On the pull down menus, you can select the device you want to be emulated on input ports 1 and 2 (game pad, zapper, pad, paddle). Note: you can't change this setting while a movie is being played or recorded.
If you check the box labeled "Attach four-score(implies four gamepads)", you won't be able to select any of these options, because the four-score allows to use 2 extra controllers.
@@ -217,17 +217,17 @@
Checking this box will replace the Start button used by controller 2 with the microphone option found on the famicom. Pressing the Microphone button is like blowing or yelling into it on the console equipment. The Port 2 controller used for the Famicom included a microphone and a volume control in place of the Start and Select buttons. This option isn't automatically detected, so it has to be manually enabled by the user. Movie files may also enable and use this feature. Both Famicom Cartridges and Famicom Disks have made use of this feature, such as both the cartridge and disk version of Zelda 1, Hikari Shinwa, and Takeshi no Chosenjo. Games other than those listed here use this feature.
-
Input Presets
-
+
Input Presets
+
This feature allow you to set the current input configuration to one of three presets. This gives you the option to quickly change from one input configuration to another (such as toggling between 1 or 2 controllers and/or toggling from controller 2 being bound to controller 1 or having its own controls).
-
To assign the current input configuration to a preset press the down arrow next to one of the presets. To assign the preset as the current input configuration press the up arrow or use the hotkey assigned to that specific preset. Preset hotkeys can be assigned in the Map Hotkeys menu.
+
To assign the current input configuration to a preset press the down arrow next to one of the presets. To assign the preset as the current input configuration press the up arrow or use the hotkey assigned to that specific preset. Preset hotkeys can be assigned in the Map Hotkeys menu.
-
Disable left+right/up+down
+
Disable left+right/up+down
By default FCEUX allows you to press both the left and right controls at the same time (or up and down). To disable this feature uncheck the checkbox on the left.
-
Auto-Hold
+
Auto-Hold
Clicking the auto hold button will allow you to assign a hotkey to the auto-hold feature.
Clicking the clear button will allow you to assign a hotkey to the clear auto-holds feature.
The following functions are available in FCEUX, in addition to standard LUA capabilities:
-
Emu library
+
Emu library
-
emu.poweron()
-
-
Executes a power cycle.
-
-
emu.softreset()
-
-
Executes a (soft) reset.
+
emu.poweron()
+
+
Executes a power cycle.
+
+
emu.softreset()
+
+
Executes a (soft) reset.
-
emu.speedmode(string mode)
-
-
Set the emulator to given speed. The mode argument can be one of these:
-
- "normal"
-
- "nothrottle" (same as turbo on fceux)
-
- "turbo"
-
- "maximum"
-
-
emu.frameadvance()
-
-
Advance the emulator by one frame. It's like pressing the frame advance button once.
-
-
Most scripts use this function in their main game loop to advance frames. Note that you can also register functions by various methods that run "dead", returning control to the emulator and letting the emulator advance the frame. For most people, using frame advance in an endless while loop is easier to comprehend so I suggest starting with that. This makes more sense when creating bots. Once you move to creating auxillary libraries, try the register() methods.
-
-
emu.pause()
-
-
Pauses the emulator.
-
-
emu.unpause()
-
-
Unpauses the emulator.
-
-
emu.exec_count(int count, function func)
-
-
Calls given function, restricting its working time to given number of lua cycles. Using this method you can ensure that some heavy operation (like Lua bot) won't freeze FCEUX.
-
-
emu.exec_time(int time, function func)
-
-
Windows-only. Calls given function, restricting its working time to given number of milliseconds (approximate). Using this method you can ensure that some heavy operation (like Lua bot) won't freeze FCEUX.
Toggles the drawing of the sprites and background planes. Set to false or nil to disable a pane, anything else will draw them.
-
-
emu.message(string message)
-
-
Displays given message on screen in the standard messages position. Use gui.text() when you need to position text.
-
-
int emu.framecount()
-
-
Returns the framecount value. The frame counter runs without a movie running so this always returns a value.
-
-
int emu.lagcount()
-
-
Returns the number of lag frames encountered. Lag frames are frames where the game did not poll for input because it missed the vblank. This happens when it has to compute too much within the frame boundary. This returns the number indicated on the lag counter.
-
-
bool emu.lagged()
-
-
Returns true if currently in a lagframe, false otherwise.
-
-
emu.setlagflag(bool value)
-
-
Sets current value of lag flag.
-
Some games poll input even in lag frames, so standard way of detecting lag (used by FCEUX and other emulators) does not work for those games, and you have to determine lag frames manually.
-
First, find RAM addresses that help you distinguish between lag and non-lag frames (e.g. an in-game frame counter that only increments in non-lag frames). Then register memory hooks that will change lag flag when needed.
-
-
bool emu.emulating()
-
-
Returns true if emulation has started, or false otherwise. Certain operations such as using savestates are invalid to attempt before emulation has started. You probably won't need to use this function unless you want to make your script extra-robust to being started too early.
-
-
bool emu.paused()
-
-
Returns true if emulator is paused, false otherwise.
-
-
bool emu.readonly()
-
Alias: movie.readonly
-
-
Returns whether the emulator is in read-only state.
-
-
While this variable only applies to movies, it is stored as a global variable and can be modified even without a movie loaded. Hence, it is in the emu library rather than the movie library.
-
-
emu.setreadonly(bool state)
-
Alias: movie.setreadonly
-
-
Sets the read-only status to read-only if argument is true and read+write if false.
-
Note: This might result in an error if the medium of the movie file is not writeable (such as in an archive file).
-
-
While this variable only applies to movies, it is stored as a global variable and can be modified even without a movie loaded. Hence, it is in the emu library rather than the movie library.
-
-
emu.getdir()
+
emu.speedmode(string mode)
+
+
Set the emulator to given speed. The mode argument can be one of these:
+
- "normal"
+
- "nothrottle" (same as turbo on fceux)
+
- "turbo"
+
- "maximum"
+
+
emu.frameadvance()
+
+
Advance the emulator by one frame. It's like pressing the frame advance button once.
+
+
Most scripts use this function in their main game loop to advance frames. Note that you can also register functions by various methods that run "dead", returning control to the emulator and letting the emulator advance the frame. For most people, using frame advance in an endless while loop is easier to comprehend so I suggest starting with that. This makes more sense when creating bots. Once you move to creating auxillary libraries, try the register() methods.
+
+
emu.pause()
+
+
Pauses the emulator.
+
+
emu.unpause()
+
+
Unpauses the emulator.
+
+
emu.exec_count(int count, function func)
+
+
Calls given function, restricting its working time to given number of lua cycles. Using this method you can ensure that some heavy operation (like Lua bot) won't freeze FCEUX.
+
+
emu.exec_time(int time, function func)
+
+
Windows-only. Calls given function, restricting its working time to given number of milliseconds (approximate). Using this method you can ensure that some heavy operation (like Lua bot) won't freeze FCEUX.
Toggles the drawing of the sprites and background planes. Set to false or nil to disable a pane, anything else will draw them.
+
+
emu.message(string message)
+
+
Displays given message on screen in the standard messages position. Use gui.text() when you need to position text.
+
+
int emu.framecount()
+
+
Returns the framecount value. The frame counter runs without a movie running so this always returns a value.
+
+
int emu.lagcount()
+
+
Returns the number of lag frames encountered. Lag frames are frames where the game did not poll for input because it missed the vblank. This happens when it has to compute too much within the frame boundary. This returns the number indicated on the lag counter.
+
+
bool emu.lagged()
+
+
Returns true if currently in a lagframe, false otherwise.
+
+
emu.setlagflag(bool value)
+
+
Sets current value of lag flag.
+
Some games poll input even in lag frames, so standard way of detecting lag (used by FCEUX and other emulators) does not work for those games, and you have to determine lag frames manually.
+
First, find RAM addresses that help you distinguish between lag and non-lag frames (e.g. an in-game frame counter that only increments in non-lag frames). Then register memory hooks that will change lag flag when needed.
+
+
bool emu.emulating()
+
+
Returns true if emulation has started, or false otherwise. Certain operations such as using savestates are invalid to attempt before emulation has started. You probably won't need to use this function unless you want to make your script extra-robust to being started too early.
+
+
bool emu.paused()
+
+
Returns true if emulator is paused, false otherwise.
+
+
bool emu.readonly()
+
Alias: movie.readonly
+
+
Returns whether the emulator is in read-only state.
+
+
While this variable only applies to movies, it is stored as a global variable and can be modified even without a movie loaded. Hence, it is in the emu library rather than the movie library.
+
+
emu.setreadonly(bool state)
+
Alias: movie.setreadonly
+
+
Sets the read-only status to read-only if argument is true and read+write if false.
+
Note: This might result in an error if the medium of the movie file is not writeable (such as in an archive file).
+
+
While this variable only applies to movies, it is stored as a global variable and can be modified even without a movie loaded. Hence, it is in the emu library rather than the movie library.
-
Returns the path of fceux.exe as a string.
+
emu.getdir()
+
+
Returns the path of fceux.exe as a string.
+
+
emu.loadrom(string filename)
+
+
Loads the ROM from the directory relative to the lua script or from the absolute path. Hence, the filename parameter can be absolute or relative path.
+
+
If the ROM can't be loaded, loads the most recent one.
+
+
emu.registerbefore(function func)
+
+
Registers a callback function to run immediately before each frame gets emulated. This runs after the next frame's input is known but before it's used, so this is your only chance to set the next frame's input using the next frame's would-be input. For example, if you want to make a script that filters or modifies ongoing user input, such as making the game think "left" is pressed whenever you press "right", you can do it easily with this.
+
+
Note that this is not quite the same as code that's placed before a call to emu.frameadvance. This callback runs a little later than that. Also, you cannot safely assume that this will only be called once per frame. Depending on the emulator's options, every frame may be simulated multiple times and your callback will be called once per simulation. If for some reason you need to use this callback to keep track of a stateful linear progression of things across frames then you may need to key your calculations to the results of emu.framecount.
+
+
Like other callback-registering functions provided by FCEUX, there is only one registered callback at a time per registering function per script. If you register two callbacks, the second one will replace the first, and the call to emu.registerbefore will return the old callback. You may register nil instead of a function to clear a previously-registered callback. If a script returns while it still has registered callbacks, FCEUX will keep it alive to call those callbacks when appropriate, until either the script is stopped by the user or all of the callbacks are de-registered.
+
+
emu.registerafter(function func)
+
+
Registers a callback function to run immediately after each frame gets emulated. It runs at a similar time as (and slightly before) gui.register callbacks, except unlike with gui.register it doesn't also get called again whenever the screen gets redrawn. Similar caveats as those mentioned in emu.registerbefore apply.
+
+
emu.registerexit(function func)
+
+
Registers a callback function that runs when the script stops. Whether the script stops on its own or the user tells it to stop, or even if the script crashes or the user tries to close the emulator, FCEUX will try to run whatever Lua code you put in here first. So if you want to make sure some code runs that cleans up some external resources or saves your progress to a file or just says some last words, you could put it here. (Of course, a forceful termination of the application or a crash from inside the registered exit function will still prevent the code from running.)
+
+
Suppose you write a script that registers an exit function and then enters an infinite loop. If the user clicks "Stop" your script will be forcefully stopped, but then it will start running its exit function. If your exit function enters an infinite loop too, then the user will have to click "Stop" a second time to really stop your script. That would be annoying. So try to avoid doing too much inside the exit function.
+
+
Note that restarting a script counts as stopping it and then starting it again, so doing so (either by clicking "Restart" or by editing the script while it is running) will trigger the callback. Note also that returning from a script generally does NOT count as stopping (because your script is still running or waiting to run its callback functions and thus does not stop... see here for more information), even if the exit callback is the only one you have registered.
+
+
bool emu.addgamegenie(string str)
+
+
Adds a Game Genie code to the Cheats menu. Returns false and an error message if the code can't be decoded. Returns false if the code couldn't be added. Returns true if the code already existed, or if it was added.
+
+
Usage: emu.addgamegenie("NUTANT")
+
+
Note that the Cheats Dialog Box won't show the code unless you close and reopen it.
+
+
bool emu.delgamegenie(string str)
+
+
Removes a Game Genie code from the Cheats menu. Returns false and an error message if the code can't be decoded. Returns false if the code couldn't be deleted. Returns true if the code didn't exist, or if it was deleted.
+
+
Usage: emu.delgamegenie("NUTANT")
+
+
Note that the Cheats Dialog Box won't show the code unless you close and reopen it.
+
+
emu.print(string str)
+
+
Puts a message into the Output Console area of the Lua Script control window. Useful for displaying usage instructions to the user when a script gets run.
+
+
emu.getscreenpixel(int x, int y, bool getemuscreen)
+
+
Returns the separate RGB components of the given screen pixel, and the palette. Can be 0-255 by 0-239, but NTSC only displays 0-255 x 8-231 of it. If getemuscreen is false, this gets background colors from either the screen pixel or the LUA pixels set, but LUA data may not match the information used to put the data to the screen. If getemuscreen is true, this gets background colors from anything behind an LUA screen element.
+
+
Usage is local r,g,b,palette = emu.getscreenpixel(5, 5, false) to retrieve the current red/green/blue colors and palette value of the pixel at 5x5.
+
+
Palette value can be 0-63, or 254 if there was an error.
+
+
You can avoid getting LUA data by putting the data into a function, and feeding the function name to emu.registerbefore.
+
+
emu.getscreenpixel(int x, int y, bool getemuscreen)
+
+
Returns the separate RGB components of the given screen pixel, and the
+
+
emu.exit()
+
+
Closes FCEUX. Useful for run-and-close scripts like automatic screenshots taking.
+
+
+
FCEU library
+
+
The FCEU library is the same as the emu library. It is left in for backwards compatibility. However, the emu library is preferred.
+
+
+
ROM Library
+
+
rom.getfilename()
+
+
Get the base filename of the ROM loaded.
+
+
rom.gethash(string type)
+
+
Get a hash of the ROM loaded, for verification. If type is "md5", returns a hex string of the MD5 hash. If type is "base64", returns a base64 string of the MD5 hash, just like the movie romChecksum value.
+
+
rom.readbyte(int address)
+
rom.readbyteunsigned(int address)
+
+
Get an unsigned byte from the actual ROM file at the given address.
+
+
This includes the header! It's the same as opening the file in a hex-editor.
+
+
rom.readbytesigned(int address)
+
+
Get a signed byte from the actual ROM file at the given address. Returns a byte that is signed.
+
+
This includes the header! It's the same as opening the file in a hex-editor.
+
+
rom.writebyte()
+
+
Write the value to the ROM at the given address. The value is modded with 256 before writing (so writing 257 will actually write 1). Negative values allowed.
+
+
Editing the header is not available.
-
emu.loadrom(string filename)
-
-
Loads the ROM from the directory relative to the lua script or from the absolute path. Hence, the filename parameter can be absolute or relative path.
-
-
If the ROM can't be loaded, loads the most recent one.
-
-
emu.registerbefore(function func)
-
-
Registers a callback function to run immediately before each frame gets emulated. This runs after the next frame's input is known but before it's used, so this is your only chance to set the next frame's input using the next frame's would-be input. For example, if you want to make a script that filters or modifies ongoing user input, such as making the game think "left" is pressed whenever you press "right", you can do it easily with this.
-
-
Note that this is not quite the same as code that's placed before a call to emu.frameadvance. This callback runs a little later than that. Also, you cannot safely assume that this will only be called once per frame. Depending on the emulator's options, every frame may be simulated multiple times and your callback will be called once per simulation. If for some reason you need to use this callback to keep track of a stateful linear progression of things across frames then you may need to key your calculations to the results of emu.framecount.
-
-
Like other callback-registering functions provided by FCEUX, there is only one registered callback at a time per registering function per script. If you register two callbacks, the second one will replace the first, and the call to emu.registerbefore will return the old callback. You may register nil instead of a function to clear a previously-registered callback. If a script returns while it still has registered callbacks, FCEUX will keep it alive to call those callbacks when appropriate, until either the script is stopped by the user or all of the callbacks are de-registered.
-
-
emu.registerafter(function func)
-
-
Registers a callback function to run immediately after each frame gets emulated. It runs at a similar time as (and slightly before) gui.register callbacks, except unlike with gui.register it doesn't also get called again whenever the screen gets redrawn. Similar caveats as those mentioned in emu.registerbefore apply.
-
-
emu.registerexit(function func)
-
-
Registers a callback function that runs when the script stops. Whether the script stops on its own or the user tells it to stop, or even if the script crashes or the user tries to close the emulator, FCEUX will try to run whatever Lua code you put in here first. So if you want to make sure some code runs that cleans up some external resources or saves your progress to a file or just says some last words, you could put it here. (Of course, a forceful termination of the application or a crash from inside the registered exit function will still prevent the code from running.)
-
-
Suppose you write a script that registers an exit function and then enters an infinite loop. If the user clicks "Stop" your script will be forcefully stopped, but then it will start running its exit function. If your exit function enters an infinite loop too, then the user will have to click "Stop" a second time to really stop your script. That would be annoying. So try to avoid doing too much inside the exit function.
-
-
Note that restarting a script counts as stopping it and then starting it again, so doing so (either by clicking "Restart" or by editing the script while it is running) will trigger the callback. Note also that returning from a script generally does NOT count as stopping (because your script is still running or waiting to run its callback functions and thus does not stop... see here for more information), even if the exit callback is the only one you have registered.
-
-
bool emu.addgamegenie(string str)
-
-
Adds a Game Genie code to the Cheats menu. Returns false and an error message if the code can't be decoded. Returns false if the code couldn't be added. Returns true if the code already existed, or if it was added.
-
-
Usage: emu.addgamegenie("NUTANT")
-
-
Note that the Cheats Dialog Box won't show the code unless you close and reopen it.
-
-
bool emu.delgamegenie(string str)
-
-
Removes a Game Genie code from the Cheats menu. Returns false and an error message if the code can't be decoded. Returns false if the code couldn't be deleted. Returns true if the code didn't exist, or if it was deleted.
-
-
Usage: emu.delgamegenie("NUTANT")
-
-
Note that the Cheats Dialog Box won't show the code unless you close and reopen it.
-
-
emu.print(string str)
-
-
Puts a message into the Output Console area of the Lua Script control window. Useful for displaying usage instructions to the user when a script gets run.
-
-
emu.getscreenpixel(int x, int y, bool getemuscreen)
-
-
Returns the separate RGB components of the given screen pixel, and the palette. Can be 0-255 by 0-239, but NTSC only displays 0-255 x 8-231 of it. If getemuscreen is false, this gets background colors from either the screen pixel or the LUA pixels set, but LUA data may not match the information used to put the data to the screen. If getemuscreen is true, this gets background colors from anything behind an LUA screen element.
-
-
Usage is local r,g,b,palette = emu.getscreenpixel(5, 5, false) to retrieve the current red/green/blue colors and palette value of the pixel at 5x5.
-
-
Palette value can be 0-63, or 254 if there was an error.
-
-
You can avoid getting LUA data by putting the data into a function, and feeding the function name to emu.registerbefore.
-
-
emu.getscreenpixel(int x, int y, bool getemuscreen)
-
-
Returns the separate RGB components of the given screen pixel, and the
-
-
emu.exit()
-
-
Closes FCEUX. Useful for run-and-close scripts like automatic screenshots taking.
-
-
-
FCEU library
-
-
The FCEU library is the same as the emu library. It is left in for backwards compatibility. However, the emu library is preferred.
-
-
-
ROM Library
-
-
rom.getfilename()
-
-
Get the base filename of the ROM loaded.
-
-
rom.gethash(string type)
-
-
Get a hash of the ROM loaded, for verification. If type is "md5", returns a hex string of the MD5 hash. If type is "base64", returns a base64 string of the MD5 hash, just like the movie romChecksum value.
-
-
rom.readbyte(int address)
-
rom.readbyteunsigned(int address)
-
-
Get an unsigned byte from the actual ROM file at the given address.
-
-
This includes the header! It's the same as opening the file in a hex-editor.
-
-
rom.readbytesigned(int address)
-
-
Get a signed byte from the actual ROM file at the given address. Returns a byte that is signed.
-
-
This includes the header! It's the same as opening the file in a hex-editor.
-
-
rom.writebyte()
-
-
Write the value to the ROM at the given address. The value is modded with 256 before writing (so writing 257 will actually write 1). Negative values allowed.
-
-
Editing the header is not available.
-
-
Memory Library
-
-
memory.readbyte(int address)
-
memory.readbyteunsigned(int address)
-
-
Get an unsigned byte from the RAM at the given address. Returns a byte regardless of emulator. The byte will always be positive.
-
-
memory.readbyterange(int address, int length)
-
-
Get a length bytes starting at the given address and return it as a string. Convert to table to access the individual bytes.
-
-
memory.readbytesigned(int address)
-
-
Get a signed byte from the RAM at the given address. Returns a byte regardless of emulator. The most significant bit will serve as the sign.
Get an unsigned word from the RAM at the given address. Returns a 16-bit value regardless of emulator. The value will always be positive.
-
If you only provide a single parameter (addressLow), the function treats it as address of little-endian word. if you provide two parameters, the function reads the low byte from addressLow and the high byte from addressHigh, so you can use it in games which like to store their variables in separate form (a lot of NES games do).
The same as above, except the returned value is signed, i.e. its most significant bit will serve as the sign.
-
-
memory.writebyte(int address, int value)
-
-
Write the value to the RAM at the given address. The value is modded with 256 before writing (so writing 257 will actually write 1). Negative values allowed.
-
-
int memory.getregister(cpuregistername)
-
-
Returns the current value of the given hardware register.
-
For example, memory.getregister("pc") will return the main CPU's current Program Counter.
-
-
Valid registers are: "a", "x", "y", "s", "p", and "pc".
-
-
memory.setregister(string cpuregistername, int value)
-
-
Sets the current value of the given hardware register.
-
For example, memory.setregister("pc",0x200) will change the main CPU's current Program Counter to 0x200.
-
-
Valid registers are: "a", "x", "y", "s", "p", and "pc".
-
-
You had better know exactly what you're doing or you're probably just going to crash the game if you try to use this function. That applies to the other memory.write functions as well, but to a lesser extent.
-
-
memory.register(int address, [int size,] function func)
-
memory.registerwrite(int address, [int size,] function func)
-
-
Registers a function to be called immediately whenever the given memory address range is written to.
-
-
address is the address in CPU address space (0x0000 - 0xFFFF).
-
-
size is the number of bytes to "watch". For example, if size is 100 and address is 0x0200, then you will register the function across all 100 bytes from 0x0200 to 0x0263. A write to any of those bytes will trigger the function. Having callbacks on a large range of memory addresses can be expensive, so try to use the smallest range that's necessary for whatever it is you're trying to do. If you don't specify any size then it defaults to 1.
-
-
The callback function will receive three arguments (address, size, value) indicating what write operation triggered the callback. If you don't care about that extra information then you can ignore it and define your callback function to not take any arguments. Since 6502 writes are always single byte, the "size" argument will always be 1.
-
-
You may use a memory.write function from inside the callback to change the value that just got written. However, keep in mind that doing so will trigger your callback again, so you must have a "base case" such as checking to make sure that the value is not already what you want it to be before writing it. Another, more drastic option is to de-register the current callback before performing the write.
-
-
If func is nil that means to de-register any memory write callbacks that the current script has already registered on the given range of bytes.
-
-
memory.registerexec(int address, [int size,] function func)
-
memory.registerrun(int address, [int size,] function func)
-
memory.registerexecute(int address, [int size,] function func)
-
-
Registers a function to be called immediately whenever the emulated system runs code located in the given memory address range.
-
-
Since "address" is the address in CPU address space (0x0000 - 0xFFFF), this doesn't take ROM banking into account, so the callback will be called for any bank, and in some cases you'll have to check current bank in your callback function.
-
-
The information about memory.register applies to this function as well. The callback will receive the same three arguments, though the "value" argument will always be 0.
-
+
Memory Library
+
+
memory.readbyte(int address)
+
memory.readbyteunsigned(int address)
+
+
Get an unsigned byte from the RAM at the given address. Returns a byte regardless of emulator. The byte will always be positive.
+
+
memory.readbyterange(int address, int length)
+
+
Get a length bytes starting at the given address and return it as a string. Convert to table to access the individual bytes.
+
+
memory.readbytesigned(int address)
+
+
Get a signed byte from the RAM at the given address. Returns a byte regardless of emulator. The most significant bit will serve as the sign.
Get an unsigned word from the RAM at the given address. Returns a 16-bit value regardless of emulator. The value will always be positive.
+
If you only provide a single parameter (addressLow), the function treats it as address of little-endian word. if you provide two parameters, the function reads the low byte from addressLow and the high byte from addressHigh, so you can use it in games which like to store their variables in separate form (a lot of NES games do).
The same as above, except the returned value is signed, i.e. its most significant bit will serve as the sign.
+
+
memory.writebyte(int address, int value)
+
+
Write the value to the RAM at the given address. The value is modded with 256 before writing (so writing 257 will actually write 1). Negative values allowed.
+
+
int memory.getregister(cpuregistername)
+
+
Returns the current value of the given hardware register.
+
For example, memory.getregister("pc") will return the main CPU's current Program Counter.
+
+
Valid registers are: "a", "x", "y", "s", "p", and "pc".
+
+
memory.setregister(string cpuregistername, int value)
+
+
Sets the current value of the given hardware register.
+
For example, memory.setregister("pc",0x200) will change the main CPU's current Program Counter to 0x200.
+
+
Valid registers are: "a", "x", "y", "s", "p", and "pc".
+
+
You had better know exactly what you're doing or you're probably just going to crash the game if you try to use this function. That applies to the other memory.write functions as well, but to a lesser extent.
+
+
memory.register(int address, [int size,] function func)
+
memory.registerwrite(int address, [int size,] function func)
+
+
Registers a function to be called immediately whenever the given memory address range is written to.
+
+
address is the address in CPU address space (0x0000 - 0xFFFF).
+
+
size is the number of bytes to "watch". For example, if size is 100 and address is 0x0200, then you will register the function across all 100 bytes from 0x0200 to 0x0263. A write to any of those bytes will trigger the function. Having callbacks on a large range of memory addresses can be expensive, so try to use the smallest range that's necessary for whatever it is you're trying to do. If you don't specify any size then it defaults to 1.
+
+
The callback function will receive three arguments (address, size, value) indicating what write operation triggered the callback. If you don't care about that extra information then you can ignore it and define your callback function to not take any arguments. Since 6502 writes are always single byte, the "size" argument will always be 1.
+
+
You may use a memory.write function from inside the callback to change the value that just got written. However, keep in mind that doing so will trigger your callback again, so you must have a "base case" such as checking to make sure that the value is not already what you want it to be before writing it. Another, more drastic option is to de-register the current callback before performing the write.
+
+
If func is nil that means to de-register any memory write callbacks that the current script has already registered on the given range of bytes.
+
+
memory.registerexec(int address, [int size,] function func)
+
memory.registerrun(int address, [int size,] function func)
+
memory.registerexecute(int address, [int size,] function func)
+
+
Registers a function to be called immediately whenever the emulated system runs code located in the given memory address range.
+
+
Since "address" is the address in CPU address space (0x0000 - 0xFFFF), this doesn't take ROM banking into account, so the callback will be called for any bank, and in some cases you'll have to check current bank in your callback function.
+
+
The information about memory.register applies to this function as well. The callback will receive the same three arguments, though the "value" argument will always be 0.
+
-
Example of custom breakpoint:
-
-
function CounterBreak()
-
ObjCtr = memory.getregister("y")
-
if ObjCtr > 0x16 then
-
gui.text(1, 9, string.format("%02X",ObjCtr))
-
emu.pause() -- or debugger.hitbreakpoint()
-
end
-
end
-
memory.registerexecute(0x863C, CounterBreak);
+
Example of custom breakpoint:
+
+
function CounterBreak()
+
ObjCtr = memory.getregister("y")
+
if ObjCtr > 0x16 then
+
gui.text(1, 9, string.format("%02X",ObjCtr))
+
emu.pause() -- or debugger.hitbreakpoint()
+
end
+
end
+
memory.registerexecute(0x863C, CounterBreak);
-
-
-
PPU Library
+
+
+
PPU Library
+
+
ppu.readbyte(int address)
-
ppu.readbyte(int address)
-
-
Get an unsigned byte from the PPU at the given address. Returns a byte regardless of emulator. The byte will always be positive.
-
-
ppu.readbyterange(int address, int length)
-
-
Get a length bytes starting at the given address and return it as a string. Convert to table to access the individual bytes.
+
Get an unsigned byte from the PPU at the given address. Returns a byte regardless of emulator. The byte will always be positive.
+
ppu.readbyterange(int address, int length)
-
Debugger Library
-
-
debugger.hitbreakpoint()
-
-
Simulates a breakpoint hit, pauses emulation and brings up the Debugger window. Use this function in your handlers of custom breakpoints.
-
-
int debugger.getcyclescount()
-
-
Returns an integer value representing the number of CPU cycles elapsed since the poweron or since the last reset of the cycles counter.
-
-
int debugger.getinstructionscount()
-
-
Returns an integer value representing the number of CPU instructions executed since the poweron or since the last reset of the instructions counter.
-
-
debugger.resetcyclescount()
-
-
Resets the cycles counter.
-
-
debugger.resetinstructionscount()
-
-
Resets the instructions counter.
-
-
-
Joypad Library
-
-
table joypad.get(int player)
-
table joypad.read(int player)
-
-
Returns a table of every game button, where each entry is true if that button is currently held (as of the last time the emulation checked), or false if it is not held. This takes keyboard inputs, not Lua. The table keys look like this (case sensitive):
-
-
up, down, left, right, A, B, start, select
-
-
Where a Lua truthvalue true means that the button is set, false means the button is unset. Note that only "false" and "nil" are considered a false value by Lua. Anything else is true, even the number 0.
-
-
joypad.read left in for backwards compatibility with older versions of FCEU/FCEUX.
-
-
table joypad.getimmediate(int player)
-
table joypad.readimmediate(int player)
-
-
Returns a table of every game button, where each entry is true if that button is held at the moment of calling the function, or false if it is not held. This function polls keyboard input immediately, allowing Lua to interact with user even when emulator is paused.
-
-
As of FCEUX 2.2.0, the function only works in Windows. In Linux this function will return nil.
-
-
table joypad.getdown(int player)
-
table joypad.readdown(int player)
-
-
Returns a table of only the game buttons that are currently held. Each entry is true if that button is currently held (as of the last time the emulation checked), or nil if it is not held.
-
-
table joypad.getup(int player)
-
table joypad.readup(int player)
-
-
Returns a table of only the game buttons that are not currently held. Each entry is nil if that button is currently held (as of the last time the emulation checked), or false if it is not held.
-
-
joypad.set(int player, table input)
-
joypad.write(int player, table input)
-
-
Set the inputs for the given player. Table keys look like this (case sensitive):
-
-
up, down, left, right, A, B, start, select
-
-
There are 4 possible values: true, false, nil, and "invert".
-
true - Forces the button on
-
false - Forces the button off
-
nil - User's button press goes through unchanged
-
"invert"- Reverses the user's button press
-
-
Any string works in place of "invert". It is suggested as a convention to use "invert" for readability, but strings like "inv", "Weird switchy mechanism", "", or "true or false" works as well as "invert".
-
-
nil and "invert" exists so the script can control individual buttons of the controller without entirely blocking the user from having any control. Perhaps there is a process which can be automated by the script, like an optimal firing pattern, but the user still needs some manual control, such as moving the character around.
-
-
joypad.write left in for backwards compatibility with older versions of FCEU/FCEUX.
-
-
-
Zapper Library
-
-
table zapper.read()
-
-
Returns the zapper data
-
When no movie is loaded this input is the same as the internal mouse input (which is used to generate zapper input, as well as the arkanoid paddle).
-
-
When a movie is playing, it returns the zapper data in the movie code.
-
-
The return table consists of 3 values: x, y, and fire. x and y are the x,y coordinates of the zapper target in terms of pixels. fire represents the zapper firing. 0 = not firing, 1 = firing
-
-
zapper.set(table input)
-
-
Sets the zapper input state.
-
-
Taple entries (nil or -1 to leave unaffected):
-
x - Forces the X position
-
y - Forces the Y position
-
fire - Forces trigger (true/1 on, false/0 off)
-
-
-
Note: The zapper is always controller 2 on the NES so there is no player argument to these functions.
-
-
-
Input Library
-
-
table input.get()
-
table input.read()
-
-
Reads input from keyboard and mouse. Returns pressed keys and the position of mouse in pixels on game screen. The function returns a table with at least two properties; table.xmouse and table.ymouse. Additionally any of these keys will be set to true if they were held at the time of executing this function:
Requests input from the user using a multiple-option message box. See gui.popup for complete usage and returns.
-
-
-
Savestate Library
-
-
object savestate.object(int slot = nil)
-
-
Create a new savestate object. Optionally you can save the current state to one of the predefined slots(1-10) using the range 1-9 for slots 1-9, and 10 for 0, QWERTY style. Using no number will create an "anonymous" savestate.
-
Note that this does not actually save the current state! You need to create this value and pass it on to the load and save functions in order to save it.
-
-
Anonymous savestates are temporary, memory only states. You can make them persistent by calling memory.persistent(state). Persistent anonymous states are deleted from disk once the script exits.
-
-
object savestate.create(int slot = nil)
-
-
savestate.create is identical to savestate.object, except for the numbering for predefined slots(1-10, 1 refers to slot 0, 2-10 refer to 1-9). It's being left in for compatibility with older scripts, and potentially for platforms with different internal predefined slot numbering.
-
-
savestate.save(object savestate)
-
-
Save the current state object to the given savestate. The argument is the result of savestate.create(). You can load this state back up by calling savestate.load(savestate) on the same object.
-
-
savestate.load(object savestate)
-
-
Load the the given state. The argument is the result of savestate.create() and has been passed to savestate.save() at least once.
-
-
If this savestate is not persistent and not one of the predefined states, the state will be deleted after loading.
-
-
savestate.persist(object savestate)
-
-
Set the given savestate to be persistent. It will not be deleted when you load this state but at the exit of this script instead, unless it's one of the predefined states. If it is one of the predefined savestates it will be saved as a file on disk.
-
-
savestate.registersave(function func)
-
-
Registers a callback function that runs whenever the user saves a state. This won't actually be called when the script itself makes a savestate, so none of those endless loops due to a misplaced savestate.save.
-
-
As with other callback-registering functions provided by FCEUX, there is only one registered callback at a time per registering function per script. Upon registering a second callback, the first is kicked out to make room for the second. In this case, it will return the first function instead of nil, letting you know what was kicked out. Registering nil will clear the previously-registered callback.
-
-
savestate.registerload(function func)
-
-
Registers a callback function that runs whenever the user loads a previously saved state. It's not called when the script itself loads a previous state, so don't worry about your script interrupting itself just because it's loading something.
-
-
The state's data is loaded before this function runs, so you can read the RAM immediately after the user loads a state, or check the new framecount. Particularly useful if you want to update lua's display right away instead of showing junk from before the loadstate.
-
-
savestate.loadscriptdata(int location)
-
-
Accuracy not yet confirmed.
-
-
Intended Function, according to snes9x LUA documentation:
-
Returns the data associated with the given savestate (data that was earlier returned by a registered save callback) without actually loading the rest of that savestate or calling any callbacks. location should be a save slot number.
-
-
-
Movie Library
+
Get a length bytes starting at the given address and return it as a string. Convert to table to access the individual bytes.
+
+
+
Debugger Library
+
+
debugger.hitbreakpoint()
+
+
Simulates a breakpoint hit, pauses emulation and brings up the Debugger window. Use this function in your handlers of custom breakpoints.
+
+
int debugger.getcyclescount()
+
+
Returns an integer value representing the number of CPU cycles elapsed since the poweron or since the last reset of the cycles counter.
+
+
int debugger.getinstructionscount()
+
+
Returns an integer value representing the number of CPU instructions executed since the poweron or since the last reset of the instructions counter.
+
+
debugger.resetcyclescount()
+
+
Resets the cycles counter.
+
+
debugger.resetinstructionscount()
+
+
Resets the instructions counter.
+
+
+
Joypad Library
+
+
table joypad.get(int player)
+
table joypad.read(int player)
+
+
Returns a table of every game button, where each entry is true if that button is currently held (as of the last time the emulation checked), or false if it is not held. This takes keyboard inputs, not Lua. The table keys look like this (case sensitive):
+
+
up, down, left, right, A, B, start, select
+
+
Where a Lua truthvalue true means that the button is set, false means the button is unset. Note that only "false" and "nil" are considered a false value by Lua. Anything else is true, even the number 0.
+
+
joypad.read left in for backwards compatibility with older versions of FCEU/FCEUX.
+
+
table joypad.getimmediate(int player)
+
table joypad.readimmediate(int player)
+
+
Returns a table of every game button, where each entry is true if that button is held at the moment of calling the function, or false if it is not held. This function polls keyboard input immediately, allowing Lua to interact with user even when emulator is paused.
+
+
As of FCEUX 2.2.0, the function only works in Windows. In Linux this function will return nil.
+
+
table joypad.getdown(int player)
+
table joypad.readdown(int player)
+
+
Returns a table of only the game buttons that are currently held. Each entry is true if that button is currently held (as of the last time the emulation checked), or nil if it is not held.
+
+
table joypad.getup(int player)
+
table joypad.readup(int player)
+
+
Returns a table of only the game buttons that are not currently held. Each entry is nil if that button is currently held (as of the last time the emulation checked), or false if it is not held.
+
+
joypad.set(int player, table input)
+
joypad.write(int player, table input)
+
+
Set the inputs for the given player. Table keys look like this (case sensitive):
+
+
up, down, left, right, A, B, start, select
+
+
There are 4 possible values: true, false, nil, and "invert".
+
true - Forces the button on
+
false - Forces the button off
+
nil - User's button press goes through unchanged
+
"invert"- Reverses the user's button press
+
+
Any string works in place of "invert". It is suggested as a convention to use "invert" for readability, but strings like "inv", "Weird switchy mechanism", "", or "true or false" works as well as "invert".
+
+
nil and "invert" exists so the script can control individual buttons of the controller without entirely blocking the user from having any control. Perhaps there is a process which can be automated by the script, like an optimal firing pattern, but the user still needs some manual control, such as moving the character around.
+
+
joypad.write left in for backwards compatibility with older versions of FCEU/FCEUX.
+
+
+
Zapper Library
+
+
table zapper.read()
+
+
Returns the zapper data
+
When no movie is loaded this input is the same as the internal mouse input (which is used to generate zapper input, as well as the arkanoid paddle).
+
+
When a movie is playing, it returns the zapper data in the movie code.
+
+
The return table consists of 3 values: x, y, and fire. x and y are the x,y coordinates of the zapper target in terms of pixels. fire represents the zapper firing. 0 = not firing, 1 = firing
+
+
zapper.set(table input)
+
+
Sets the zapper input state.
+
+
Taple entries (nil or -1 to leave unaffected):
+
x - Forces the X position
+
y - Forces the Y position
+
fire - Forces trigger (true/1 on, false/0 off)
+
+
+
Note: The zapper is always controller 2 on the NES so there is no player argument to these functions.
+
+
+
Input Library
+
+
table input.get()
+
table input.read()
+
+
Reads input from keyboard and mouse. Returns pressed keys and the position of mouse in pixels on game screen. The function returns a table with at least two properties; table.xmouse and table.ymouse. Additionally any of these keys will be set to true if they were held at the time of executing this function:
Requests input from the user using a multiple-option message box. See gui.popup for complete usage and returns.
+
+
+
Savestate Library
+
+
object savestate.object(int slot = nil)
+
+
Create a new savestate object. Optionally you can save the current state to one of the predefined slots(1-10) using the range 1-9 for slots 1-9, and 10 for 0, QWERTY style. Using no number will create an "anonymous" savestate.
+
Note that this does not actually save the current state! You need to create this value and pass it on to the load and save functions in order to save it.
+
+
Anonymous savestates are temporary, memory only states. You can make them persistent by calling memory.persistent(state). Persistent anonymous states are deleted from disk once the script exits.
+
+
object savestate.create(int slot = nil)
+
+
savestate.create is identical to savestate.object, except for the numbering for predefined slots(1-10, 1 refers to slot 0, 2-10 refer to 1-9). It's being left in for compatibility with older scripts, and potentially for platforms with different internal predefined slot numbering.
+
+
savestate.save(object savestate)
+
+
Save the current state object to the given savestate. The argument is the result of savestate.create(). You can load this state back up by calling savestate.load(savestate) on the same object.
+
+
savestate.load(object savestate)
+
+
Load the the given state. The argument is the result of savestate.create() and has been passed to savestate.save() at least once.
+
+
If this savestate is not persistent and not one of the predefined states, the state will be deleted after loading.
+
+
savestate.persist(object savestate)
+
+
Set the given savestate to be persistent. It will not be deleted when you load this state but at the exit of this script instead, unless it's one of the predefined states. If it is one of the predefined savestates it will be saved as a file on disk.
+
+
savestate.registersave(function func)
+
+
Registers a callback function that runs whenever the user saves a state. This won't actually be called when the script itself makes a savestate, so none of those endless loops due to a misplaced savestate.save.
+
+
As with other callback-registering functions provided by FCEUX, there is only one registered callback at a time per registering function per script. Upon registering a second callback, the first is kicked out to make room for the second. In this case, it will return the first function instead of nil, letting you know what was kicked out. Registering nil will clear the previously-registered callback.
+
+
savestate.registerload(function func)
+
+
Registers a callback function that runs whenever the user loads a previously saved state. It's not called when the script itself loads a previous state, so don't worry about your script interrupting itself just because it's loading something.
+
+
The state's data is loaded before this function runs, so you can read the RAM immediately after the user loads a state, or check the new framecount. Particularly useful if you want to update lua's display right away instead of showing junk from before the loadstate.
+
+
savestate.loadscriptdata(int location)
+
+
Accuracy not yet confirmed.
+
+
Intended Function, according to snes9x LUA documentation:
+
Returns the data associated with the given savestate (data that was earlier returned by a registered save callback) without actually loading the rest of that savestate or calling any callbacks. location should be a save slot number.
Loads and plays a movie from the directory relative to the Lua script or from the absolute path. If read_only is true, the movie will be loaded in read-only mode. The default is read+write.
A pauseframe can be specified, which controls which frame will auto-pause the movie. By default, this is off. A true value is returned if the movie loaded correctly.
Starts recording a movie, using the filename, relative to the Lua script.
-
-
An optional save_type can be specified. If set to 0 (default), it will record from a power on state, and automatically do so. This is the recommended setting for creating movies. This can also be set to 1 for savestate or 2 for saveram movies.
-
-
A third parameter specifies an author string. If included, it will be recorded into the movie file.
-
-
bool movie.active()
-
-
Returns true if a movie is currently loaded and false otherwise. (This should be used to guard against Lua errors when attempting to retrieve movie information).
-
-
int movie.framecount()
-
-
Returns the current frame count. (Has the same affect as emu.framecount)
-
-
string movie.mode()
-
-
Returns the current state of movie playback. Returns one of the following:
-
-
- "record"
-
- "playback"
-
- "finished"
-
- "taseditor"
-
- nil
-
-
movie.rerecordcounting(bool counting)
-
-
Turn the rerecord counter on or off. Allows you to do some brute forcing without inflating the rerecord count.
-
-
movie.stop()
-
movie.close()
-
-
Stops movie playback. If no movie is loaded, it throws a Lua error.
-
-
int movie.length()
-
-
Returns the total number of frames of the current movie. Throws a Lua error if no movie is loaded.
-
-
string movie.name()
-
string movie.getname()
-
-
Returns the filename of the current movie with path. Throws a Lua error if no movie is loaded.
-
-
movie.getfilename()
-
-
Returns the filename of the current movie with no path. Throws a Lua error if no movie is loaded.
-
-
movie.rerecordcount()
-
-
Returns the rerecord count of the current movie. Throws a Lua error if no movie is loaded.
-
-
movie.replay()
-
movie.playbeginning()
-
-
Performs the Play from Beginning function. Movie mode is switched to read-only and the movie loaded will begin playback from frame 1.
-
-
If no movie is loaded, no error is thrown and no message appears on screen.
-
-
bool movie.readonly()
-
bool movie.getreadonly()
-
Alias: emu.getreadonly
-
-
FCEUX keeps the read-only status even without a movie loaded.
-
-
Returns whether the emulator is in read-only state.
-
-
While this variable only applies to movies, it is stored as a global variable and can be modified even without a movie loaded. Hence, it is in the emu library rather than the movie library.
-
-
movie.setreadonly(bool state)
-
Alias: emu.setreadonly
-
-
FCEUX keeps the read-only status even without a movie loaded.
-
-
Sets the read-only status to read-only if argument is true and read+write if false.
-
Note: This might result in an error if the medium of the movie file is not writeable (such as in an archive file).
-
-
While this variable only applies to movies, it is stored as a global variable and can be modified even without a movie loaded. Hence, it is in the emu library rather than the movie library.
-
-
bool movie.recording()
-
-
Returns true if there is a movie loaded and in record mode.
-
-
bool movie.playing()
-
-
Returns true if there is a movie loaded and in play mode.
-
-
bool movie.ispoweron()
-
-
Returns true if the movie recording or loaded started from 'Start'.
-
Returns false if the movie uses a save state.
-
Opposite of movie.isfromsavestate()
-
-
bool movie.isfromsavestate()
-
-
Returns true if the movie recording or loaded started from 'Now'.
-
Returns false if the movie was recorded from a reset.
-
Opposite of movie.ispoweron()
-
-
string movie.name()
-
-
If a movie is loaded it returns the name of the movie, else it throws an error.
-
-
bool movie.readonly()
-
-
Returns the state of read-only. True if in playback mode, false if in record mode.
-
-
-
GUI Library
-
-
gui.pixel(int x, int y, type color)
-
gui.drawpixel(int x, int y, type color)
-
gui.setpixel(int x, int y, type color)
-
gui.writepixel(int x, int y, type color)
-
-
Draw one pixel of a given color at the given position on the screen. See drawing notes and color notes at the bottom of the page.
-
-
gui.getpixel(int x, int y)
-
-
Returns the separate RGBA components of the given pixel set by gui.pixel. This only gets LUA pixels set, not background colors.
-
-
Usage is local r,g,b,a = gui.getpixel(5, 5) to retrieve the current red/green/blue/alpha values of the LUA pixel at 5x5.
-
-
See emu.getscreenpixel() for an emulator screen variant.
-
-
gui.line(int x1, int y1, int x2, int y2 [, color [, skipfirst]])
-
gui.drawline(int x1, int y1, int x2, int y2 [, color [, skipfirst]])
-
-
Draws a line between the two points. The x1,y1 coordinate specifies one end of the line segment, and the x2,y2 coordinate specifies the other end. If skipfirst is true then this function will not draw anything at the pixel x1,y1, otherwise it will. skipfirst is optional and defaults to false. The default color for the line is solid white, but you may optionally override that using a color of your choice. See also drawing notes and color notes at the bottom of the page.
-
-
gui.box(int x1, int y1, int x2, int y2 [, fillcolor [, outlinecolor]]))
-
gui.drawbox(int x1, int y1, int x2, int y2 [, fillcolor [, outlinecolor]]))
-
gui.rect(int x1, int y1, int x2, int y2 [, fillcolor [, outlinecolor]]))
-
gui.drawrect(int x1, int y1, int x2, int y2 [, fillcolor [, outlinecolor]]))
-
-
Draws a rectangle between the given coordinates of the emulator screen for one frame. The x1,y1 coordinate specifies any corner of the rectangle (preferably the top-left corner), and the x2,y2 coordinate specifies the opposite corner.
-
-
The default color for the box is transparent white with a solid white outline, but you may optionally override those using colors of your choice. Also see drawing notes and color notes.
-
-
gui.text(int x, int y, string str [, textcolor [, backcolor]])
-
gui.drawtext(int x, int y, string str [, textcolor [, backcolor]])
-
-
Draws a given string at the given position. textcolor and backcolor are optional. See 'on colors' at the end of this page for information. Using nil as the input or not including an optional field will make it use the default.
-
-
gui.parsecolor(color)
-
-
Returns the separate RGBA components of the given color.
-
For example, you can say local r,g,b,a = gui.parsecolor('orange') to retrieve the red/green/blue values of the preset color orange. (You could also omit the a in cases like this.) This uses the same conversion method that FCEUX uses internally to support the different representations of colors that the GUI library uses. Overriding this function will not change how FCEUX interprets color values, however.
-
-
gui.savescreenshot()
-
Makes a screenshot of the FCEUX emulated screen, and saves it to the appropriate folder. Performs identically to pressing the Screenshot hotkey.
-
-
gui.savescreenshotas(string name)
-
Makes a screenshot of the FCEUX emulated screen, and saves it to the appropriate folder. However, this one receives a file name for the screenshot.
-
-
string gui.gdscreenshot(bool getemuscreen)
-
-
Takes a screen shot of the image and returns it in the form of a string which can be imported by the gd library using the gd.createFromGdStr() function.
-
-
This function is provided so as to allow FCEUX to not carry a copy of the gd library itself. If you want raw RGB32 access, skip the first 11 bytes (header) and then read pixels as Alpha (always 0), Red, Green, Blue, left to right then top to bottom, range is 0-255 for all colors.
-
-
If getemuscreen is false, this gets background colors from either the screen pixel or the Lua pixels set, but Lua data may not match the information used to put the data to the screen. If getemuscreen is true, this gets background colors from anything behind a Lua screen element.
-
-
Warning: Storing screen shots in memory is not recommended. Memory usage will blow up pretty quick. One screen shot string eats around 230 KB of RAM.
Draws an image on the screen. gdimage must be in truecolor gd string format.
-
-
Transparency is fully supported. Also, if alphamul is specified then it will modulate the transparency of the image even if it's originally fully opaque. (alphamul=1.0 is normal, alphamul=0.5 is doubly transparent, alphamul=3.0 is triply opaque, etc.)
-
-
dx,dy determines the top-left corner of where the image should draw. If they are omitted, the image will draw starting at the top-left corner of the screen.
-
-
gui.gdoverlay is an actual drawing function (like gui.box and friends) and thus must be called every frame, preferably inside a gui.register'd function, if you want it to appear as a persistent image onscreen.
-
-
Here is an example that loads a PNG from file, converts it to gd string format, and draws it once on the screen:
-
local gdstr = gd.createFromPng("myimage.png"):gdStr()
-
gui.gdoverlay(gdstr)
-
-
gui.opacity(int alpha)
-
-
Scales the transparency of subsequent draw calls. An alpha of 0.0 means completely transparent, and an alpha of 1.0 means completely unchanged (opaque). Non-integer values are supported and meaningful, as are values greater than 1.0. It is not necessary to use this function (or the less-recommended gui.transparency) to perform drawing with transparency, because you can provide an alpha value in the color argument of each draw call. However, it can sometimes be convenient to be able to globally modify the drawing transparency.
-
-
gui.transparency(int trans)
-
-
Scales the transparency of subsequent draw calls. Exactly the same as gui.opacity, except the range is different: A trans of 4.0 means completely transparent, and a trans of 0.0 means completely unchanged (opaque).
-
-
function gui.register(function func)
-
-
Register a function to be called between a frame being prepared for displaying on your screen and it actually happening. Used when that 1 frame delay for rendering is not acceptable.
Brings up a modal popup dialog box (everything stops until the user dismisses it). The box displays the message tostring(msg). This function returns the name of the button the user clicked on (as a string).
-
-
type determines which buttons are on the dialog box, and it can be one of the following: 'ok', 'yesno', 'yesnocancel', 'okcancel', 'abortretryignore'.
-
type defaults to 'ok' for gui.popup, or to 'yesno' for input.popup.
-
-
icon indicates the purpose of the dialog box (or more specifically it dictates which title and icon is displayed in the box), and it can be one of the following: 'message', 'question', 'warning', 'error'.
-
icon defaults to 'message' for gui.popup, or to 'question' for input.popup.
-
-
Try to avoid using this function much if at all, because modal dialog boxes can be irritating.
-
-
Linux users might want to install xmessage to perform the work. Otherwise the dialog will appear on the shell and that's less noticeable.
-
-
-
Sound Library
-
-
table sound.get()
-
-
Returns current state of PSG channels in big array.
-
-
table:
-
{
-
rp2a03:
-
{
-
square1:
-
{
-
volume, -- 0.0-1.0
-
frequency, -- in hertz
-
midikey, -- 0-127
-
duty, -- 0:12.5% 1:25% 2:50% 3:75%
-
regs: -- raw register values
-
{
-
frequency -- raw freq register value
-
}
-
},
-
square2:
-
{
-
volume, -- 0.0-1.0
-
frequency, -- in hertz
-
midikey, -- 0-127
-
duty, -- 0:12.5% 1:25% 2:50% 3:75%
-
regs: -- raw register values
-
{
-
frequency -- raw freq register value
-
}
-
},
-
triangle:
-
{
-
volume, -- 0.0-1.0
-
frequency, -- in hertz (correct?)
-
midikey, -- 0-127 (correct?)
-
regs: -- raw register values
-
{
-
frequency -- raw freq register value
-
}
-
},
-
noise:
-
{
-
volume, -- 0.0-1.0
-
short, -- true or false
-
frequency, -- in hertz (correct?)
-
midikey, -- 0-127 (correct?)
-
regs: -- raw register values
-
{
-
frequency -- raw freq register value
-
}
-
},
-
dpcm:
-
{
-
volume, -- 0.0-1.0
-
frequency, -- in hertz (correct?)
-
midikey, -- 0-127 (correct?)
-
dmcaddress, -- start position of the sample
-
dmcsize, -- size of the sample, in bytes
-
dmcloop, -- true:looped sample, false:oneshot
-
dmcseed, -- InitialRawDALatch
-
regs: -- raw register values
-
{
-
frequency -- raw freq register value
-
}
-
}
-
}
-
}
-
-
-
TAS Editor Library
-
-
taseditor.registerauto(function func)
-
taseditor.registermanual(function func)
-
bool taseditor.engaged()
-
bool taseditor.markedframe(int frame)
-
int taseditor.getmarker(int frame)
-
int taseditor.setmarker(int frame)
-
taseditor.clearmarker(int frame)
-
string taseditor.getnote(int index)
-
taseditor.setnote(int index, string newtext)
-
int taseditor.getcurrentbranch()
-
string taseditor.getrecordermode()
-
int taseditor.getsuperimpose()
-
int taseditor.getlostplayback()
-
int taseditor.getplaybacktarget()
-
taseditor.setplayback(int frame)
-
taseditor.stopseeking()
-
taseditor.getselection()
-
taseditor.setselection()
-
int taseditor.getinput(int frame, int joypad)
-
taseditor.submitinputchange(int frame, int joypad, int input)
-
taseditor.submitinsertframes(int frame, int number)
-
taseditor.submitdeleteframes(int frame, int number)
-
int taseditor.applyinputchanges([string name])
-
taseditor.clearinputchanges()
-
-
For full description of these functions refer to TAS Editor Manual.
-
-
-
Bitwise Operations
-
-
The following bit functions were added to FCEUX internally to compensate for Lua's lack of them. But it also supports all operations from LuaBitOp module, since it is also embedded in FCEUX.
Returns an integer with the given bits turned on. Parameters should be smaller than 31.
-
-
Appendix
-
-
On drawing
-
-
A general warning about drawing is that it is always one frame behind unless you use gui.register. This is because you tell the emulator to paint something but it will actually paint it when generating the image for the next frame. So you see your painting, except it will be on the image of the next frame. You can prevent this with gui.register because it gives you a quick chance to paint before blitting.
-
-
Dimensions & color depths you can paint in:
-
--320x239, 8bit color (confirm?)
-
256x224, 8bit color (confirm?)
-
-
On colors
-
-
Colors can be of a few types.
-
Int: use the a formula to compose the color as a number (depends on color depth)
-
String: Can either be a HTML colors, simple colors, or internal palette colors.
-
HTML string: "#rrggbb" ("#228844") or #rrggbbaa if alpha is supported.
Array: Example: {255,112,48,96} means {red=255, green=112, blue=48, alpha=96}
-
Table: Example: {r=255,g=112,b=48,a=96} means {red=255, green=112, blue=48, alpha=96}
-
Palette: Example: "P00" for Palette 00. "P3F" for palette 3F. P40-P7F are for LUA.
-
-
For transparancy use "clear".
-
+
Starts recording a movie, using the filename, relative to the Lua script.
+
+
An optional save_type can be specified. If set to 0 (default), it will record from a power on state, and automatically do so. This is the recommended setting for creating movies. This can also be set to 1 for savestate or 2 for saveram movies.
+
+
A third parameter specifies an author string. If included, it will be recorded into the movie file.
+
+
bool movie.active()
+
+
Returns true if a movie is currently loaded and false otherwise. (This should be used to guard against Lua errors when attempting to retrieve movie information).
+
+
int movie.framecount()
+
+
Returns the current frame count. (Has the same affect as emu.framecount)
+
+
string movie.mode()
+
+
Returns the current state of movie playback. Returns one of the following:
+
+
- "record"
+
- "playback"
+
- "finished"
+
- "taseditor"
+
- nil
+
+
movie.rerecordcounting(bool counting)
+
+
Turn the rerecord counter on or off. Allows you to do some brute forcing without inflating the rerecord count.
+
+
movie.stop()
+
movie.close()
+
+
Stops movie playback. If no movie is loaded, it throws a Lua error.
+
+
int movie.length()
+
+
Returns the total number of frames of the current movie. Throws a Lua error if no movie is loaded.
+
+
string movie.name()
+
string movie.getname()
+
+
Returns the filename of the current movie with path. Throws a Lua error if no movie is loaded.
+
+
movie.getfilename()
+
+
Returns the filename of the current movie with no path. Throws a Lua error if no movie is loaded.
+
+
movie.rerecordcount()
+
+
Returns the rerecord count of the current movie. Throws a Lua error if no movie is loaded.
+
+
movie.replay()
+
movie.playbeginning()
+
+
Performs the Play from Beginning function. Movie mode is switched to read-only and the movie loaded will begin playback from frame 1.
+
+
If no movie is loaded, no error is thrown and no message appears on screen.
+
+
bool movie.readonly()
+
bool movie.getreadonly()
+
Alias: emu.getreadonly
+
+
FCEUX keeps the read-only status even without a movie loaded.
+
+
Returns whether the emulator is in read-only state.
+
+
While this variable only applies to movies, it is stored as a global variable and can be modified even without a movie loaded. Hence, it is in the emu library rather than the movie library.
+
+
movie.setreadonly(bool state)
+
Alias: emu.setreadonly
+
+
FCEUX keeps the read-only status even without a movie loaded.
+
+
Sets the read-only status to read-only if argument is true and read+write if false.
+
Note: This might result in an error if the medium of the movie file is not writeable (such as in an archive file).
+
+
While this variable only applies to movies, it is stored as a global variable and can be modified even without a movie loaded. Hence, it is in the emu library rather than the movie library.
+
+
bool movie.recording()
+
+
Returns true if there is a movie loaded and in record mode.
+
+
bool movie.playing()
+
+
Returns true if there is a movie loaded and in play mode.
+
+
bool movie.ispoweron()
+
+
Returns true if the movie recording or loaded started from 'Start'.
+
Returns false if the movie uses a save state.
+
Opposite of movie.isfromsavestate()
+
+
bool movie.isfromsavestate()
+
+
Returns true if the movie recording or loaded started from 'Now'.
+
Returns false if the movie was recorded from a reset.
+
Opposite of movie.ispoweron()
+
+
string movie.name()
+
+
If a movie is loaded it returns the name of the movie, else it throws an error.
+
+
bool movie.readonly()
+
+
Returns the state of read-only. True if in playback mode, false if in record mode.
+
+
+
GUI Library
+
+
gui.pixel(int x, int y, type color)
+
gui.drawpixel(int x, int y, type color)
+
gui.setpixel(int x, int y, type color)
+
gui.writepixel(int x, int y, type color)
+
+
Draw one pixel of a given color at the given position on the screen. See drawing notes and color notes at the bottom of the page.
+
+
gui.getpixel(int x, int y)
+
+
Returns the separate RGBA components of the given pixel set by gui.pixel. This only gets LUA pixels set, not background colors.
+
+
Usage is local r,g,b,a = gui.getpixel(5, 5) to retrieve the current red/green/blue/alpha values of the LUA pixel at 5x5.
+
+
See emu.getscreenpixel() for an emulator screen variant.
+
+
gui.line(int x1, int y1, int x2, int y2 [, color [, skipfirst]])
+
gui.drawline(int x1, int y1, int x2, int y2 [, color [, skipfirst]])
+
+
Draws a line between the two points. The x1,y1 coordinate specifies one end of the line segment, and the x2,y2 coordinate specifies the other end. If skipfirst is true then this function will not draw anything at the pixel x1,y1, otherwise it will. skipfirst is optional and defaults to false. The default color for the line is solid white, but you may optionally override that using a color of your choice. See also drawing notes and color notes at the bottom of the page.
+
+
gui.box(int x1, int y1, int x2, int y2 [, fillcolor [, outlinecolor]]))
+
gui.drawbox(int x1, int y1, int x2, int y2 [, fillcolor [, outlinecolor]]))
+
gui.rect(int x1, int y1, int x2, int y2 [, fillcolor [, outlinecolor]]))
+
gui.drawrect(int x1, int y1, int x2, int y2 [, fillcolor [, outlinecolor]]))
+
+
Draws a rectangle between the given coordinates of the emulator screen for one frame. The x1,y1 coordinate specifies any corner of the rectangle (preferably the top-left corner), and the x2,y2 coordinate specifies the opposite corner.
+
+
The default color for the box is transparent white with a solid white outline, but you may optionally override those using colors of your choice. Also see drawing notes and color notes.
+
+
gui.text(int x, int y, string str [, textcolor [, backcolor]])
+
gui.drawtext(int x, int y, string str [, textcolor [, backcolor]])
+
+
Draws a given string at the given position. textcolor and backcolor are optional. See 'on colors' at the end of this page for information. Using nil as the input or not including an optional field will make it use the default.
+
+
gui.parsecolor(color)
+
+
Returns the separate RGBA components of the given color.
+
For example, you can say local r,g,b,a = gui.parsecolor('orange') to retrieve the red/green/blue values of the preset color orange. (You could also omit the a in cases like this.) This uses the same conversion method that FCEUX uses internally to support the different representations of colors that the GUI library uses. Overriding this function will not change how FCEUX interprets color values, however.
+
+
gui.savescreenshot()
+
Makes a screenshot of the FCEUX emulated screen, and saves it to the appropriate folder. Performs identically to pressing the Screenshot hotkey.
+
+
gui.savescreenshotas(string name)
+
Makes a screenshot of the FCEUX emulated screen, and saves it to the appropriate folder. However, this one receives a file name for the screenshot.
+
+
string gui.gdscreenshot(bool getemuscreen)
+
+
Takes a screen shot of the image and returns it in the form of a string which can be imported by the gd library using the gd.createFromGdStr() function.
+
+
This function is provided so as to allow FCEUX to not carry a copy of the gd library itself. If you want raw RGB32 access, skip the first 11 bytes (header) and then read pixels as Alpha (always 0), Red, Green, Blue, left to right then top to bottom, range is 0-255 for all colors.
+
+
If getemuscreen is false, this gets background colors from either the screen pixel or the Lua pixels set, but Lua data may not match the information used to put the data to the screen. If getemuscreen is true, this gets background colors from anything behind a Lua screen element.
+
+
Warning: Storing screen shots in memory is not recommended. Memory usage will blow up pretty quick. One screen shot string eats around 230 KB of RAM.
Draws an image on the screen. gdimage must be in truecolor gd string format.
+
+
Transparency is fully supported. Also, if alphamul is specified then it will modulate the transparency of the image even if it's originally fully opaque. (alphamul=1.0 is normal, alphamul=0.5 is doubly transparent, alphamul=3.0 is triply opaque, etc.)
+
+
dx,dy determines the top-left corner of where the image should draw. If they are omitted, the image will draw starting at the top-left corner of the screen.
+
+
gui.gdoverlay is an actual drawing function (like gui.box and friends) and thus must be called every frame, preferably inside a gui.register'd function, if you want it to appear as a persistent image onscreen.
+
+
Here is an example that loads a PNG from file, converts it to gd string format, and draws it once on the screen:
+
local gdstr = gd.createFromPng("myimage.png"):gdStr()
+
gui.gdoverlay(gdstr)
+
+
gui.opacity(int alpha)
+
+
Scales the transparency of subsequent draw calls. An alpha of 0.0 means completely transparent, and an alpha of 1.0 means completely unchanged (opaque). Non-integer values are supported and meaningful, as are values greater than 1.0. It is not necessary to use this function (or the less-recommended gui.transparency) to perform drawing with transparency, because you can provide an alpha value in the color argument of each draw call. However, it can sometimes be convenient to be able to globally modify the drawing transparency.
+
+
gui.transparency(int trans)
+
+
Scales the transparency of subsequent draw calls. Exactly the same as gui.opacity, except the range is different: A trans of 4.0 means completely transparent, and a trans of 0.0 means completely unchanged (opaque).
+
+
function gui.register(function func)
+
+
Register a function to be called between a frame being prepared for displaying on your screen and it actually happening. Used when that 1 frame delay for rendering is not acceptable.
Brings up a modal popup dialog box (everything stops until the user dismisses it). The box displays the message tostring(msg). This function returns the name of the button the user clicked on (as a string).
+
+
type determines which buttons are on the dialog box, and it can be one of the following: 'ok', 'yesno', 'yesnocancel', 'okcancel', 'abortretryignore'.
+
type defaults to 'ok' for gui.popup, or to 'yesno' for input.popup.
+
+
icon indicates the purpose of the dialog box (or more specifically it dictates which title and icon is displayed in the box), and it can be one of the following: 'message', 'question', 'warning', 'error'.
+
icon defaults to 'message' for gui.popup, or to 'question' for input.popup.
+
+
Try to avoid using this function much if at all, because modal dialog boxes can be irritating.
+
+
Linux users might want to install xmessage to perform the work. Otherwise the dialog will appear on the shell and that's less noticeable.
+
+
+
Sound Library
+
+
table sound.get()
+
+
Returns current state of PSG channels in big array.
+
+
table:
+
{
+
rp2a03:
+
{
+
square1:
+
{
+
volume, -- 0.0-1.0
+
frequency, -- in hertz
+
midikey, -- 0-127
+
duty, -- 0:12.5% 1:25% 2:50% 3:75%
+
regs: -- raw register values
+
{
+
frequency -- raw freq register value
+
}
+
},
+
square2:
+
{
+
volume, -- 0.0-1.0
+
frequency, -- in hertz
+
midikey, -- 0-127
+
duty, -- 0:12.5% 1:25% 2:50% 3:75%
+
regs: -- raw register values
+
{
+
frequency -- raw freq register value
+
}
+
},
+
triangle:
+
{
+
volume, -- 0.0-1.0
+
frequency, -- in hertz (correct?)
+
midikey, -- 0-127 (correct?)
+
regs: -- raw register values
+
{
+
frequency -- raw freq register value
+
}
+
},
+
noise:
+
{
+
volume, -- 0.0-1.0
+
short, -- true or false
+
frequency, -- in hertz (correct?)
+
midikey, -- 0-127 (correct?)
+
regs: -- raw register values
+
{
+
frequency -- raw freq register value
+
}
+
},
+
dpcm:
+
{
+
volume, -- 0.0-1.0
+
frequency, -- in hertz (correct?)
+
midikey, -- 0-127 (correct?)
+
dmcaddress, -- start position of the sample
+
dmcsize, -- size of the sample, in bytes
+
dmcloop, -- true:looped sample, false:oneshot
+
dmcseed, -- InitialRawDALatch
+
regs: -- raw register values
+
{
+
frequency -- raw freq register value
+
}
+
}
+
}
+
}
+
+
+
TAS Editor Library
+
+
taseditor.registerauto(function func)
+
taseditor.registermanual(function func)
+
bool taseditor.engaged()
+
bool taseditor.markedframe(int frame)
+
int taseditor.getmarker(int frame)
+
int taseditor.setmarker(int frame)
+
taseditor.clearmarker(int frame)
+
string taseditor.getnote(int index)
+
taseditor.setnote(int index, string newtext)
+
int taseditor.getcurrentbranch()
+
string taseditor.getrecordermode()
+
int taseditor.getsuperimpose()
+
int taseditor.getlostplayback()
+
int taseditor.getplaybacktarget()
+
taseditor.setplayback(int frame)
+
taseditor.stopseeking()
+
taseditor.getselection()
+
taseditor.setselection()
+
int taseditor.getinput(int frame, int joypad)
+
taseditor.submitinputchange(int frame, int joypad, int input)
+
taseditor.submitinsertframes(int frame, int number)
+
taseditor.submitdeleteframes(int frame, int number)
+
int taseditor.applyinputchanges([string name])
+
taseditor.clearinputchanges()
+
+
For full description of these functions refer to TAS Editor Manual.
+
+
+
Bitwise Operations
+
+
The following bit functions were added to FCEUX internally to compensate for Lua's lack of them. But it also supports all operations from LuaBitOp module, since it is also embedded in FCEUX.
+
+
int AND(int n1, int n2, ..., int nn)
+
+
Binary logical AND of all the given integers.
+
+
int OR(int n1, int n2, ..., int nn)
+
+
Binary logical OR of all the given integers.
+
+
int XOR(int n1, int n2, ..., int nn)
+
+
Binary logical XOR of all the given integers.
+
+
int BIT(int n1, int n2, ..., int nn)
+
+
Returns an integer with the given bits turned on. Parameters should be smaller than 31.
+
+
Appendix
+
+
On drawing
+
+
A general warning about drawing is that it is always one frame behind unless you use gui.register. This is because you tell the emulator to paint something but it will actually paint it when generating the image for the next frame. So you see your painting, except it will be on the image of the next frame. You can prevent this with gui.register because it gives you a quick chance to paint before blitting.
+
+
Dimensions & color depths you can paint in:
+
--320x239, 8bit color (confirm?)
+
256x224, 8bit color (confirm?)
+
+
On colors
+
+
Colors can be of a few types.
+
Int: use the a formula to compose the color as a number (depends on color depth)
+
String: Can either be a HTML colors, simple colors, or internal palette colors.
+
HTML string: "#rrggbb" ("#228844") or #rrggbbaa if alpha is supported.
Lua is built into FCEUX as of 2.1.2, and luapack DLL files are no longer needed in this and later versions.
-
To run lua scripts in older versions of FCEUX, you will need the lua pack which can be found here. The .dll files must be unzipped in the same folder as fceux.exe.
-
-
Core Lua Documentation
-
-
If you have never programmed, you will probably want to start by learning the basic of Lua, which is too broad for the scope of this help file. Try searching on the Internet for "Lua tutorial". As of this writing, it's official homepage is http://www.lua.org/
+
To run lua scripts in older versions of FCEUX, you will need the lua pack which can be found here. The .dll files must be unzipped in the same folder as fceux.exe.
+
+
Core Lua Documentation
+
+
If you have never programmed, you will probably want to start by learning the basic of Lua, which is too broad for the scope of this help file. Try searching on the Internet for "Lua tutorial". As of this writing, it's official homepage is http://www.lua.org/
If you are familiar with any programming language you will probably not have too much difficulty adjusting to the syntax and structure of Lua. You will probably also find useful information on the Internet.
-
-
GUI Frontend
+
+
GUI Frontend
To use a Lua script, you need to create one in a text editor. The name of the file created should end in .lua to indicate that it is a Lua script.
@@ -204,7 +204,7 @@
To end a Lua script, choose "Stop Lua Script" ***from where***.
-
FCEUX Lua Basics
+
FCEUX Lua Basics
Your script will be constructed according to the rules of Lua, but you will use FCEUX-specific functions to interact with the emulator. For example, one of the most often-used functions is emu.frameadvance() which will tell the emulator to advance exactly one frame, which is the basic unit of time on an NES.
The following Lua libraries are integrated into FCEUX win32-executable (statically linked) and are available for using in your scripts. You can also use any other Lua library by placing its .dll files into FCEUX folder.
-
IUP library
+
IUP library
IUP (Portable User Interface) is a toolkit for building graphical user interfaces.
IM is a toolkit for Digital Imaging. The main goal of the library is to provide a simple API and abstraction of images for applications.
File formats supported: TIFF, BMP, PNG, JPEG, GIF and AVI. Image representation includes scientific data types. About a hundred Image Processing operations are available.
The library contains functions to support both vector and image applications, and the visualization surface can be either a window or a more abstract surface, such as Image, Clipboard, Metafile, PS, and so on.
LuaSocket is a Lua extension library that is composed by two parts: a C core that provides support for the TCP and UDP transport layers, and a set of Lua modules that add support for the SMTP (sending e-mails), HTTP (WWW access) and FTP (uploading and downloading files) protocols and other functionality commonly needed by applications that deal with the Internet.
Memory watch is a tool designed to values of specific known memory values in the game's RAM. Memory watch does not find values. To find useful values to monitor, see Cheats, Ram filter, Hex Editor, and Debugger.
+
Memory watch is a tool designed to values of specific known memory values in the game's RAM. Memory watch does not find values. To find useful values to monitor, see Cheats, Ram filter, Hex Editor, and Debugger.
Inserting Values
@@ -196,7 +196,7 @@
To display a ram value, simply type its address into one of the address fields. The name field allows you to put a brief description of the value.
-
Prefixes
+
Prefixes
You must put in the hexi-decimal value of the address, but the value will be displayed will be decimal by default.
@@ -207,24 +207,24 @@
Use a prefix of "X" to watch a 2 byte value in hex.
-
Saving/Loading Watch files
+
Saving/Loading Watch files
You can save your addresses into watch files, as well as loading previous files using the standard save,load,new options in the File menu.
-
FCEUX uses the /memw folder by default but you can specify a new default folder in the Directory Override menu.
+
FCEUX uses the /memw folder by default but you can specify a new default folder in the Directory Override menu.
-
Options Menu
+
Options Menu
-
If you select Load on Start up, Memory watch will load up automatically when FCEU is started.
+
If you select Load on Start up, Memory watch will load up automatically when FCEU is started.
-
If you select Load Last File on Start up, the most recent file in the Recent folder will be loaded when memory watch is loaded.
+
If you select Load Last File on Start up, the most recent file in the Recent folder will be loaded when memory watch is loaded.
-
If you select Collapse to 1 Column (or press the right arrow button on the bottom left of the dialog), the memory watch dialog is reduced to just 1 column.
+
If you select Collapse to 1 Column (or press the right arrow button on the bottom left of the dialog), the memory watch dialog is reduced to just 1 column.
Frozen Memory Addresses
-
If one of the watched addresses is frozen by the cheats dialog or the hex editor, it will display blue in the memory watch dialog.
+
If one of the watched addresses is frozen by the cheats dialog or the hex editor, it will display blue in the memory watch dialog.
Memory Change Monitor
@@ -240,7 +240,7 @@
Reset will reset the count to 0.
-
Usage Example:
+
Usage Example:
As an example of the memory change monitoring, Let's say we are recording a movie of the game Super C and want to keep track of when the game lags.
The ram address 001C functions as a "lag flag". It will remain 0, then change to a positive value on a frame that the game lags.
Unless the movie starts from the console power-on or from reset, the movie file might also contain a savestate that loads the beginning point of the game. Movie files don’t contain any sound or image data. Such data is not needed, because the emulator can reconstruct it during movie playback.
-
Movie files in FCEUX are .fm2 files. The file format is unique to FCEUX and not compatible with other movie recording versions of FCE Ultra. Movie files from other versions (.fcm) can be converted to .fm2 for playback with the .fcm to .fm2 converter.
+
Movie files in FCEUX are .fm2 files. The file format is unique to FCEUX and not compatible with other movie recording versions of FCE Ultra. Movie files from other versions (.fcm) can be converted to .fm2 for playback with the .fcm to .fm2 converter.
-
Movie features in FCEUX are designed specifically for making Tool-assisted Speedruns. For more information visit TASVideos.
+
Movie features in FCEUX are designed specifically for making Tool-assisted Speedruns. For more information visit TASVideos.
Recording Movies
@@ -205,13 +205,13 @@
At anytime while recording, you can make a *savestate. This is a snapshot of the game's current memory contents. Once a savestate is made, it can be loaded with the *loadstate command. This will return the movie back to the spot in the game where the savestate was made. This can be used to undo mistakes or to test different strategies for a particular segment.
-
(The default key for making a savestate is "I" and the default key for loading a state is "P". Both of these can be assigned under the Map Hotkeys Menu). Both can also be access through the File > Savestate Menu
+
(The default key for making a savestate is "I" and the default key for loading a state is "P". Both of these can be assigned under the Map Hotkeys Menu). Both can also be access through the File > Savestate Menu
-
Tool Assisted movies take advantage of slowing the emulator down in order to increase precision of the movie making process. Navigating to NES > Emulation Speed > Slow down or pressing the "-" key will slow down emulation. NES > Emulation Speed > Speed up or the "=" will speed it up. (These can be re-mapped in the Map Hotkeys Menu).
+
Tool Assisted movies take advantage of slowing the emulator down in order to increase precision of the movie making process. Navigating to NES > Emulation Speed > Slow down or pressing the "-" key will slow down emulation. NES > Emulation Speed > Speed up or the "=" will speed it up. (These can be re-mapped in the Map Hotkeys Menu).
Even greater precision can be made using the frame advance key. Pressing the frame advance key will pause emulation and advance it a single frame (1/60th of a second NTSC ). By holding down input and pressing the frame advance key, it will record that input for that particular frame.
The Frame counter displays what frame the movie is currently on. If the movie is playing in read-only mode, it will also display the total number of frames in the movie. The default key for toggling the Frame Counter display is the "." (period) key. (This can be re-mapped in the Map Hotkeys Menu).
+
The Frame counter displays what frame the movie is currently on. If the movie is playing in read-only mode, it will also display the total number of frames in the movie. The default key for toggling the Frame Counter display is the "." (period) key. (This can be re-mapped in the Map Hotkeys Menu).
Frame Advance
-
The frame advance key ("backlash" key by default. Re-mappable under the Map Hotkeys Menu) will advance the game by a single frame and then pause the game. If the hotkey is held down, it will auto advance quickly through the game.
+
The frame advance key ("backlash" key by default. Re-mappable under the Map Hotkeys Menu) will advance the game by a single frame and then pause the game. If the hotkey is held down, it will auto advance quickly through the game.
This is a critical tool when perfecting input in movie recording.
Metadata
-
When you record a new movie via the record movie dialog there is an author field. This sends the info to the .fm2 file in the form of comment Author [author name] (see .fm2).
+
When you record a new movie via the record movie dialog there is an author field. This sends the info to the .fm2 file in the form of comment Author [author name] (see .fm2).
Any line in the .fm2 that starts with "comment" is known as metadata. You can include any number of comments manually by editing the .fm2 file with any text editor.
@@ -267,9 +267,9 @@
Subtitles
-
FCEUX now supports subtitles in the .fm2 file format. Subtitles will be displayed on the screen automatically as a movie plays. You can turn on/off subtitles by navigating to Config > Movie Options > Display movie subtitles (see Movie options).
+
FCEUX now supports subtitles in the .fm2 file format. Subtitles will be displayed on the screen automatically as a movie plays. You can turn on/off subtitles by navigating to Config > Movie Options > Display movie subtitles (see Movie options).
2A03 CPU is a 6502-compatible CPU without the decimal mode (CLD and SED do nothing). It has an on-die sound generator, very limited DMA capability, and an input device controller that can be accessed through the 2A03 registers.
-
6502 CPU Memory Map
+
6502 CPU Memory Map
Address Range Size in bytesNotes (Page size = 256bytes)
(Hexadecimal)
@@ -299,7 +299,7 @@
Most games use the basic on board ram. The address range of this ram is $0000-$07FF. This translates to 2048 possible ram values.
-
Pages
+
Pages
This ram is broken down into 8 pages. A "page" is a block of 256 ram values.
@@ -317,26 +317,26 @@
There are always the following blocks:
-
Sprite DataBlock 2
+
Sprite DataBlock 2
I've yet to see map a game that does not use this block solely for sprite data. It will contain the "ID" numbers for all the items currently on the screen. Simply put, this data is precisely the data you see on the screen. For making TAS movies this is not useful data. If you are using cheat search and have narrowed it down your search to a few values, you can immediately discard any $02xx values.
In games with a lot of sprite data, I've seen blocks 1 & 3 also reserved for sprite data.
-
Music & Sound FXBlock 1 or 7, generally
+
Music & Sound FXBlock 1 or 7, generally
This one has more deviation, but almost all games reserve an entire block for memory allocated to the game's Music and Sound FX. Again, for TAS purposes these values are not *useful. By finding even 1 of these values, you can eliminate that block from your search possibilities. Finding which block is reserved for music is often quite simple with the Hex editor. Watching the ram values with the game playing, you can see which addresses "move to the beat".
*Actually they can come in handy for "dancing to the beat"
-
Player & Enemy StatsBlocks 1,3,4,5 generally (any or all of these)
+
Player & Enemy StatsBlocks 1,3,4,5 generally (any or all of these)
This is your "sweet spot" for movie making, as often you will be wanting to track the players speed or coordinates, enemy energy, or enemy coordinates.
These values rarely (if at all) reside outside blocks 1, 3, 4, or 5. This knowledge already reduces your search possibilities in half!
-
Rows
-
+
Rows
+
Each block is broken down into 16 "rows" of addresses. For example, in block 3, the first row is $030x ($0300-$030F).
Each row of 16* will contain similar data. For instance all x coordinates will generally be in the same row. So xxx0 might be the main characters x position. xxxx1 would be "enemy 1" (1st enemy loaded onto the screen), and so on.
@@ -345,7 +345,7 @@
*Super Mario Bros. 2 (U) is a rare example that uses rows of 10
-
Columns
+
Columns
A column would be all the values of a block that share the same last digit. So a column would be 16 addresses such as $0300, $0310, $0320, etc.
@@ -355,28 +355,28 @@
If the next row ($031x) is x positions. $0310 would be the player's x position. The remaining positions of that row would correspond to the other player/enemy x positions in line with the hp values of the previous row.
-
Example
+
Example
-
These distinctions are easier to see in a visual example. This is the enemy/player stats as they are mapped in the game Teenage Mutant Ninja Turtles.
+
These distinctions are easier to see in a visual example. This is the enemy/player stats as they are mapped in the game Teenage Mutant Ninja Turtles.
-
Block 4
-
P W1 W2 W3 E1 E2 E3 E4 E5 E6 E7 E8 X X X X
-
Sprite ID: 040x: 09 00 00 00 00 9E 9E 9E 9E 00 00 00 00 00 00 00
Many users of FCEUX do not investigate the luaScripts folder, or, for that matter, ignore lua scripting altogether. The purpose of this text is to let users know that knowing how to create lua scripts is not a requirement in using them. Indeed, there are several scripts that, if you just load them, will explain themselves enough that you don't need to know how to program at all in order to use them. Besides, they shouldn't need to be re-programmed anyway if you are to use them, for if they needed programming experience just to be used, their existence is largely defeated by that very fact!
+
Many users of FCEUX do not investigate the luaScripts folder, or, for that matter, ignore lua scripting altogether. The purpose of this text is to let users know that knowing how to create lua scripts is not a requirement in using them. Indeed, there are several scripts that, if you just load them, will explain themselves enough that you don't need to know how to program at all in order to use them. Besides, they shouldn't need to be re-programmed anyway if you are to use them, for if they needed programming experience just to be used, their existence is largely defeated by that very fact!
FCEUX itself is a program that you load. Our amazing programmers did all the work already so you don't need to program up your own FCEUX to run it, do you? The same can be said of these scripts.
-
So, open the luaScripts folder and actually take the time to look at some of these scripts. You may use a text-editing program to open these if you so wish.
+
So, open the luaScripts folder and actually take the time to look at some of these scripts. You may use a text-editing program to open these if you so wish.
-
General Purpose scripts:
+
General Purpose scripts:
These may be used with any game freely. Else, the "General" part of General Purpose doesn't apply.
@@ -206,7 +206,7 @@
-
Game Specific scripts:
+
Game Specific scripts:
These scripts are built specifically for certain games. Attempting to run them while you've loaded another ROM will likely cause undesired results. The meaning of "undesired results" in this case are things like crashing the game, causing it to glitch in other ways, or having nonsense numbers and pixels show up.
@@ -235,7 +235,7 @@
-
Auxiliary Functions scripts:
+
Auxiliary Functions scripts:
These scripts exist to make the life of programmers easier. As such, if you don't program, you may skip over these scripts. These should not be run by themselves, for they themselves probably don't have any programming to do any work usefully. It's like giving yourself a clip of bullets with no gun to use.
The NES architecture includes a 6502 CPU as well as a custom video controller known as a PPU (Picture Processing Unit). The PPU's video memory is separated from the main CPU memory and can be read/written via special ports (see PPU Memory).
+
The NES architecture includes a 6502 CPU as well as a custom video controller known as a PPU (Picture Processing Unit). The PPU's video memory is separated from the main CPU memory and can be read/written via special ports (see PPU Memory).
The PPU viewer will only display the contents of the current PPU memory. It does not alter game data in any way.
@@ -202,7 +202,7 @@
Right clicking on one of the PPU panels will change the palette it is shown with, cycling though pattern palettes, then sprite ones, then a ninth fixed grey palette (useful for inspecting CHR if all the palettes are currently black).
Putting the mouse cursor over a tile will display the tile address. Moving cursor over palette color will give palette address.
-
When Code/Data Logger is running, you can also use the "Mask unused graphics" feature. Alternatively, you can only mask tiles that were used (drawn or otherwise accessed) and emphasize the tiles that weren't used (e.g. in order to find secret sprites).
+
When Code/Data Logger is running, you can also use the "Mask unused graphics" feature. Alternatively, you can only mask tiles that were used (drawn or otherwise accessed) and emphasize the tiles that weren't used (e.g. in order to find secret sprites).
Note: this feature only works with games that use CHR ROM, because Code/Data Logger only logs accesses to CHR ROM.
Every PAL PPU has de-emphasis bits for green and red colors swapped. This option simulates that behavior.
-
NTSC Color Emulation
+
NTSC Color Emulation
If enabled, FCEUX will simulate actual NTSC signal processing. The result should be the actual colors you would see if outputting to an actual NTSC television.
It is designed to filter RAM values just like in the Cheat Search dialog. However, it features many options that are lacking in the Cheat Search dialog. Among these are search undo, search preview, a modulus filter, a data size option, signed/unsigned/hex options, autosearch, and several more compare by options.
+
It is designed to filter RAM values just like in the Cheat Search dialog. However, it features many options that are lacking in the Cheat Search dialog. Among these are search undo, search preview, a modulus filter, a data size option, signed/unsigned/hex options, autosearch, and several more compare by options.
-
Documentation on this dialog can be found on TASVideos here.
+
Documentation on this dialog can be found on TASVideos here.
-
Hotkeys
+
Hotkeys
-
Hotkeys can be assigned to common search commands so they can be easily selected while in the main window.
+
Hotkeys can be assigned to common search commands so they can be easily selected while in the main window.
It is designed to filter ram values just like in the Cheat Search dialog. However, it features many options that are lacking in the Cheat Search dialog. Among these are search undo, search preview, a modulus filter, a data size option, signed/unsigned/hex options, autosearch, and several more compare by options.
+
It is designed to filter ram values just like in the Cheat Search dialog. However, it features many options that are lacking in the Cheat Search dialog. Among these are search undo, search preview, a modulus filter, a data size option, signed/unsigned/hex options, autosearch, and several more compare by options.
-
Documentation on this dialog can be found on TASVideos here.
+
Documentation on this dialog can be found on TASVideos here.
Sets the Master volume level. You can also set volume levels using the sound volume up, volume down, mute, and volume normal hotkeys under map hotkeys menu.
+
Sets the Master volume level. You can also set volume levels using the sound volume up, volume down, mute, and volume normal hotkeys under map hotkeys menu.
TAS Editor is an overhaul in the logic of creating TAS movies (see Tool Assisted Speedruns). It is a powerful new design that takes movie making from a "recording" concept to a "creating an input file" way of thinking.
+
TAS Editor is an overhaul in the logic of creating TAS movies (see Tool Assisted Speedruns). It is a powerful new design that takes movie making from a "recording" concept to a "creating an input file" way of thinking.
In the 2.2.0 release the TAS Editor was completely redesigned and rewritten, incorporating new experimental ideas.
(written by Ugly Joe, author of the Text Hooker tool)
-
What is Text Hooker?
+
What is Text Hooker?
Here's a premise for you. Suppose you've pirated a bunch of Japanese NES roms and you load one of them up at random. Cool music. Cool title screen. You go to start a game, put in ???? at the name entry screen, and get to the actual game. Well, big surprise here, it's an RPG. You soon realize that you have no idea what people are saying, what shops are selling, or what your battle options are. It can be fun to trial-and-error for a while, but you're ultimately stuck in the first town. Time to load up a new ROM.
@@ -198,7 +198,7 @@
This is why I made the Text Hooker. What it allows you to do is highlight text boxes in the game and copy the kana right to the clipboard. I no longer have to look up stuff, I can just copy from the emulator, paste into the website, and go from there. While developing it, I took it a bit further by adding a (shoddy) translator right into the app, and added features such as word substitutions (so you only have to look up the word once and then the app will know what it is as soon as you copy it). What you end up with is kind of like a translator's notebook. It keeps commonly used words in a dictionary and helps you get through a Japanese game without having too much knowledge of the Japanese language.
-
What do I need to use to use it?
+
What do I need to use to use it?
Some knowledge of the Japanese language
I really can't say how much you need to know, but I suppose the more you know the better. I could be wrong, but I think you need to know at least something about the language before you can start copy/pasting translations.
@@ -213,7 +213,7 @@
Duh, you'll need a game to play. Find it yourself.
-
How do I use the Text Hooker?
+
How do I use the Text Hooker?
First of all, you need to make your table file. The text hooker doesn't use Thingy tables, but uses a modified Thingy table instead. So, make your standard Thingy table file, but save it with a .tht extension (instead of .tbl). What you need to add to the table are the dakuten and handakuten marks (tenten and maru). The byte for the dakuten mark needs to be set to tenten and the byte for the handakuten mark needs to be set to tenten. Like:
Overclocks the console by adding dummy scanlines to the usual PPU loop, causing CPU to run more cycles per frame. Can be done in two different ways: by adding Post-render scanlines and by adding Vblank scanlines. The method to be used depends on the game. Maximum value is 999.
+
Overclocks the console by adding dummy scanlines to the usual PPU loop, causing CPU to run more cycles per frame. Can be done in two different ways: by adding Post-render scanlines and by adding Vblank scanlines. The method to be used depends on the game. Maximum value is 999.
Explains the various toggle switch commands in the top two groups of commands under the Config Menu.
@@ -196,18 +196,18 @@
Region
-
Allows to choose between NTSC (224p@60fps), PAL and Dendy (240p@50fps) modes. For PAL, FCEUX will detect the proper choice when loading a ROM and set the flag accordingly (based on file name, where (E) is used by GoodTools to mark European ROMs). Dendy mode (sometimes also called Hybrid) is a modification of the NTSC one, it was used in some Famiclones and supports games released for the NTSC region, slowing them down to PAL speed.
+
Allows to choose between NTSC (224p@60fps), PAL and Dendy (240p@50fps) modes. For PAL, FCEUX will detect the proper choice when loading a ROM and set the flag accordingly (based on file name, where (E) is used by GoodTools to mark European ROMs). Dendy mode (sometimes also called Hybrid) is a modification of the NTSC one, it was used in some Famiclones and supports games released for the NTSC region, slowing them down to PAL speed.
Note: you can't change this setting while a movie is being played or recorded.
-
PPU (Sub-menu)
+
PPU (Sub-menu)
-
New PPU / Old PPU
+
New PPU / Old PPU
As of FCEUX 2.1.2, FCEUX has a new PPU core. The new PPU has improved accuracy and greater game compatibility than the old PPU. However, some games may not work properly and there will be slight timing differences that would hurt movie compatibility. Also then New PPU is much slower than the Old PPU. Therefore, the old PPU is still the preferred setting.
Note: you can't change this setting while a movie is being played or recorded.
-
Enable (Sub-menu)
+
Enable (Sub-menu)
Run in Background
@@ -221,43 +221,43 @@
Auto-savestates
-
Enables the Auto-save feature. If enabled, FCEUX will make periodic savestates (once per every 256 frames) as you play or record a movie. You can right-click and select the "load last auto-save" in the context menu or press "Load Last Auto-save" hotkey to back up to the last auto-save savestate.
+
Enables the Auto-save feature. If enabled, FCEUX will make periodic savestates (once per every 256 frames) as you play or record a movie. You can right-click and select the "load last auto-save" in the context menu or press "Load Last Auto-save" hotkey to back up to the last auto-save savestate.
-
Frame Adv. - Skip Lag
+
Frame Adv. - Skip Lag
-
This feature, if enabled, will cause the frame advance key (see movie recording) to skip over lag frames. It does this by reading the lag counter and skipping past any frames where input is not polled.
+
This feature, if enabled, will cause the frame advance key (see movie recording) to skip over lag frames. It does this by reading the lag counter and skipping past any frames where input is not polled.
For instance, in a 30fps game (such as double dragon), frame advance will advance 2 frames instead of 1.
-
Backup Savestates
+
Backup Savestates
-
Enabled by default. This option allows for savestate & loadstate Undo (& redo). (see context menu)
+
Enabled by default. This option allows for savestate & loadstate Undo (& redo). (see context menu)
-
Compress Savestates
+
Compress Savestates
Enabled by default. This option compresses non movie savestates.
Game Genie ROM
-
Allows the use of the game genie ROM. You must have a game genie ROM named gg.rom (it is safe to rename a game genie.nes file to gg.rom) and it must be in the FCEUX base directory (which is the folder fceux.exe is in unless you specified a different folder in the Directory Override Menu).
+
Allows the use of the game genie ROM. You must have a game genie ROM named gg.rom (it is safe to rename a game genie.nes file to gg.rom) and it must be in the FCEUX base directory (which is the folder fceux.exe is in unless you specified a different folder in the Directory Override Menu).
If enabled, FCEUX will open gg.rom first when you load a new game. Any codes applied in the game genie screen will be applied to the game just like on a real NES.
(Remember that enabling/disabling Game Genie emulation will not take effect until a new game is loaded)
If enabled, FCEUX will make a special savestate every time you close ROM, and will automatically load the savestate when you open this ROM next time, so you can continue from where you left the game. In addition, when this option is enabled, FCEUX automatically loads the last used ROM on startup.
-
Display (Sub-Menu)
+
Display (Sub-Menu)
Input Display
@@ -265,7 +265,7 @@
When input comes from a movie file rather than then user, it is displayed in a different color (silver)
-
The input display can also be toggled by hotkey. The default key for toggling the Input display is the "," (comma) key. (This can be re-mapped in the Map Hotkeys Menu).
+
The input display can also be toggled by hotkey. The default key for toggling the Input display is the "," (comma) key. (This can be re-mapped in the Map Hotkeys Menu).
Lag Counter
@@ -274,21 +274,21 @@
The lag counter value is stored in savestates.
-
Displaying the lag counter can also be toggled by hotkey. The default key is the "/" (slash) key. (This can be re-mapped in the Map Hokeys Menu).
+
Displaying the lag counter can also be toggled by hotkey. The default key is the "/" (slash) key. (This can be re-mapped in the Map Hokeys Menu).
Frame Counter
Toggles the display of the frame counter. The frame counter will increment once per frame.
-
The frame counter display can also be toggled by hotkey. The default key is the "." (period) key. (This can be re-mapped in the Map Hotkeys Menu).
+
The frame counter display can also be toggled by hotkey. The default key is the "." (period) key. (This can be re-mapped in the Map Hotkeys Menu).
Rerecord Counter
Toggles the display of the number of Rerecords done when making a movie. The Rerecord counter will increment every time you load a savestate in Recording mode.
-
The rerecord counter display can also be toggled by hotkey. The default key is the "M" key. (This can be re-mapped in the Map Hotkeys Menu).
+
The rerecord counter display can also be toggled by hotkey. The default key is the "M" key. (This can be re-mapped in the Map Hotkeys Menu).
Movie status icon
@@ -310,14 +310,14 @@
Turning this off will turn off the objects (sprites) in the game.
-
Note: You can set the default color when the Backgrounds are turned off. To do so, open fceux.cfg and change the value of the entry named: gNoBGFillColor
-
-
+
Note: You can set the default color when the Backgrounds are turned off. To do so, open fceux.cfg and change the value of the entry named: gNoBGFillColor
+
+
Save Config File
-
-
Saves current settings to fceux.cfg. Normally settings are not saved until FCEUX is closed.
-
-
+
+
Saves current settings to fceux.cfg. Normally settings are not saved until FCEUX is closed.
Normally, when logging to window, the Tracer only shows the log if you pause emulator by Pause or Frame Advance hotkey, or by snapping the Debugger. But there is the option to automatically update the log window while the game runs - this is normally useless, unless it is working with the Code/Data Logger to only show newly-executed instructions.
-
When the code is logged to window, you can browse it using mouse wheel or vertical scrollbar. Double-clicking any address in this window will bring the Debugger window at this address. Right-clicking any address allows you to label the address (see Symbolic Debug).
+
When the code is logged to window, you can browse it using mouse wheel or vertical scrollbar. Double-clicking any address in this window will bring the Debugger window at this address. Right-clicking any address allows you to label the address (see Symbolic Debug).
You can customize the format of text output in the log:
@@ -205,7 +205,7 @@
whether to log current frame number, cycles counter, instructions counter
whether to log emulator messages (such as "State 1 loaded")
whether to log Breakpoint Hits (when you use debugger while tracing)
-
whether to apply Symbolic Debug names when logging. See Debugger section for details
+
whether to apply Symbolic Debug names when logging. See Debugger section for details
For nice visualization of JSRs nesting you can use Stack Pointer for lines tabbing. Since NES games mostly use stack for subroutine calls (and rarely store variables in the stack), this option will likely produce a more readable disassembly. With this option you may also want to put registers data to the left from disassembly text, so they won't be tabbed.
This section describes potential problems/question that could arise when using FCEUX.
-
Slow emulation / Sound crackle
+
Slow emulation / Sound crackle
FCEUX may not run well on slow CPUs.
Ensure that you're using the Old PPU, because the New PPU engine is very slow. Check Config -> PPU -> Old PPU.
-
Sound crackle
+
Sound crackle
If you enable hardware acceleration and Vsync (Wait for VBlank), and your monitor has a framerate different from 60FPS, you may experience minor sound cracle. This is a known issue and will probably be resolved in a future release.
-
Emulated picture is blurred (similar to the bilinear filter)
+
Emulated picture is blurred (similar to the bilinear filter)
Try choosing different options in the "DirectDraw" list in the Video config dialog.
-
Slow savestates when recording movies
+
Slow savestates when recording movies
On slower computers, savestates can be slow with long movies. A small speedup can be done by disabling Config -> Enable -> Backup savestates.
-
The colors in game X do not look right!
+
The colors in game X do not look right!
There's no such thing as a universally right palette for NES games.
FCEUX uses the color palette of the old FCEU / FCEUXD branches. Also FCEUX comes pre-packaged with several additional color palettes. For more information see Palette config and Palette options.
-
I converted a .fcm file to .fm2, but the .fm2 desyncs
+
I converted a .fcm file to .fm2, but the .fm2 desyncs
Depending on what version of FCEU / Game your .fcm was made, there maybe a number of sync issues. In addition, the .fm2 conversion tool has had some issues on certain operating systems including Vista and Mac. you can try using an external program for movie conversion.
-
Can't find FDS Bios image when I attempt to load a .fds game!
+
Can't find FDS Bios image when I attempt to load a .fds game!
-
FCEUX requires the FDS Bios to be named disksys.rom. It must be located in the root directory (where fceux.exe is stored) or in the folder of the FDS Directory override (see Directory overrides).
+
FCEUX requires the FDS Bios to be named disksys.rom. It must be located in the root directory (where fceux.exe is stored) or in the folder of the FDS Directory override (see Directory overrides).
In addition, there are some bad versions of disksys.rom. The one FDS requires is 8192 bytes in size.
-
How can I use Netplay / Where can I get FCEU Server?
+
How can I use Netplay / Where can I get FCEU Server?
Currently, the Windows version of FCEUX is barely compatible with the FCEU-server code. This is a known issue and will probably be resolved in a future release.
-
I have a Game Genie rom, how can I use it with FCEUX?
+
I have a Game Genie rom, how can I use it with FCEUX?
-
While FCEUX has a Game Genie code converter, you can also use game genie codes with an old-school Game Genie ROM. It must be named gg.rom and must be placed in the root directory (where fceux.exe is stored). You must also check Config->Enable->Game Genie ROM in the main menu. Then the Game Genie ROM will activate every time you open a ROM, so you can enter GG codes letter-by-letter like they did in the past.
+
While FCEUX has a Game Genie code converter, you can also use game genie codes with an old-school Game Genie ROM. It must be named gg.rom and must be placed in the root directory (where fceux.exe is stored). You must also check Config->Enable->Game Genie ROM in the main menu. Then the Game Genie ROM will activate every time you open a ROM, so you can enter GG codes letter-by-letter like they did in the past.
Alternatively, you can use a hotkey (Alt+Enter by default) or a double-click (if the "Switch fullscreen by double-click" option is enabled in GUI options).
+
Alternatively, you can use a hotkey (Alt+Enter by default) or a double-click (if the "Switch fullscreen by double-click" option is enabled in GUI options).
-
Enter full screen mode after game is loaded
+
Enter full screen mode after game is loaded
If checked, FCEUX will enter full screen mode when a game is loaded.
-
Hide mouse cursor
+
Hide mouse cursor
If checked, FCEUX will hide mouse cursor when in full screen mode.
-
Mode
+
Mode
Sets the image size during full screen mode. By default this is automatically set to match current display resolution. You can change the resolution by entering different values.
-
Special Scaler
+
Special Scaler
Within this box is eight options: hq2x, Scale2x, NTSC 2x, hq3x, Scale3x, Prescale2x, Prescale3x, and Prescale4x.
- Scale2x/3x just attempts to render out the corners of the pixels to make them look a bit rounder. "2x" means two times bigger than 1x1 and "3x" means three times bigger than 1x1.
- Hq2x/3x does a much better job than scale2x/3x by smearing the pixels together with a slight blur. However, Hq2x/3x requires a faster computer for decent speed (at least 1 GHz and above). "2x" means two times bigger than 1x1 and "3x" means three times bigger than 1x1.
- NTSC 2x simulates visual artifacts that are produced by analog (composite) video sygnal that the real console generates.
- Prescale2x/3x/4x upscales the source picture using a pixel based (nearest neighbor) algorithm, that allows to change the level of interpolation, applied when using hardware acceleration.
-
Sync Method
+
Sync Method
If the emulator is running poorly, trying out these sync options can help make it run smoother (fix image tearing).
-
DirectDraw
+
DirectDraw
If the image is blurry, here you can disable hardware acceleration.
Windowed Settings
-
Size Multiplier
+
Size Multiplier
Takes the image size and multiples the X and Y by a specific amount. You can also change these by clicking and dragging the border of the FCEUX window.
-
Force Integral Scaling Factors
+
Force Integral Scaling Factors
If checked, FCEUX window can only be stretched by even amounts (1x, 2x, 3x, etc.). If unchecked, it can be stretched by any amount.
When you are resizing FCEUX window by dragging its borders, you can hold Shift to temporarily invert this option.
-
Force Aspect Ratio Correction
+
Force Aspect Ratio Correction
Checking this will only allow the correct aspect ratio while resizing the window.
-
Special Scaler
+
Special Scaler
Within this box is eight options: hq2x, Scale2x, NTSC 2x, hq3x, Scale3x, Prescale2x, Prescale3x, and Prescale4x.
-
Sync Method
+
Sync Method
If the emulator is running poorly, trying out these sync options can help make it run smoother (fix image tearing).
-
DirectDraw
+
DirectDraw
If Vsync doesn't work, here you can enable hardware acceleration.
@@ -245,36 +245,36 @@
The following options affect both Fullscreen and windowed mode.
-
Aspect ratio
+
Aspect ratio
-
Best Fit
+
Best Fit
This is checked by default, so FCEUX will automatically maintain correct aspect ratio for any size of the window. If you uncheck this, the image will be stretched to fill the whole window area.
-
BG color
+
BG color
When window size is wider or taller than image size, empty areas of the window are colored black by default. Checking this option will color these areas according to current "background" color of NES palette.
-
Square pixels
+
Square pixels
This is checked by default, so FCEUX will limit the max size of the image to make all pixels share the same width/height. If you uncheck this, the image will be stretched to fill the whole width or height of the window area.
-
TV Aspect
+
TV Aspect
Check this if you want to change the image aspect ratio (e.g. to 4:3). You can enter different values in adjacent text fields.
-
Drawing Area
+
Drawing Area
-
First Line
+
First Line
Sets the first scan line for NTSC and PAL Modes. This should be left on the default of 8 for NTSC and 0 for PAL.
-
Last Line
+
Last Line
Sets the last scan line for NTSC and PAL Modes. This should be left on the default of 231 for NTSC and 239 for PAL.
-
Clip left and right sides (8 px on each)
+
Clip left and right sides (8 px on each)
If enabled, 8 pixels from each side of the windows will be removed. Some NES games show grapical artifacts on the sides of screen when scrolling (on real hardware too!), so you may hide those artifacts by checking the option.
-
Emulation
+
Emulation
-
Allow more than 8 sprites per scanline
+
Allow more than 8 sprites per scanline
On real NES hardware, more than 8 sprites on the screen causes flickering. Enabling this option can reduce flickering by allowing more sprites to be visible at once. But if you prefer to stay "true" to NES hardware, this should not be checked, because some games rely on the limitation.
This release includes a multitude of new features, major fixes, and enhancements.
-
The 2.1 new release fixes some bugs of 2.1.0a, improves the accuracy of the sound core, and adds useability enhancements to the windows port.
-
-
Common - Bug fixes
+
The 2.1 new release fixes some bugs of 2.1.0a, improves the accuracy of the sound core, and adds useability enhancements to the windows port.
+
+
Common - Bug fixes
-
Fixed reported issue 2746924 (md5_asciistr() doesn't produce correct string)
-
Made default save slot 0 instead of 1
-
-
-
Improved Sound core/PPU
-
-
Fixed the noise value, it seems that the noise logic was shifting the values to the left by 1 when reloading, but this doesn't work for PAL since one of the PAL reload value is odd, so fix the logic and used the old tables. Revert a stupid CPU ignore logic in PPU. Sorry about that.
-
Updated with the correct values for the noise and DMC table,
-
Fixed the CPU unofficial opcode ATX, ORing with correct constant $FF instead of $EE, as tested by blargg's. These fixes passes the IRQ flags test from blargg, and also one more opcode test from blargg's cpu.nes test.
-
Square 1 & square 2 volume controls no longer backwards
-
Length counters for APU now correct variables
-
-
-
NewPPU (still experimental, enabled by setting newppu 1 in the config file)
-
-
Added experimental $2004 reading support to play micro machines with (little) shakes, and fixed some timing in the new PPU.
-
Added palette reading cases for the new PPU.
+
Fixed reported issue 2746924 (md5_asciistr() doesn't produce correct string)
+
Made default save slot 0 instead of 1
-
Win32
+
Improved Sound core/PPU
+
+
Fixed the noise value, it seems that the noise logic was shifting the values to the left by 1 when reloading, but this doesn't work for PAL since one of the PAL reload value is odd, so fix the logic and used the old tables. Revert a stupid CPU ignore logic in PPU. Sorry about that.
+
Updated with the correct values for the noise and DMC table,
+
Fixed the CPU unofficial opcode ATX, ORing with correct constant $FF instead of $EE, as tested by blargg's. These fixes passes the IRQ flags test from blargg, and also one more opcode test from blargg's cpu.nes test.
+
Square 1 & square 2 volume controls no longer backwards
+
Length counters for APU now correct variables
+
-
Minor Bug fixes
+
NewPPU (still experimental, enabled by setting newppu 1 in the config file)
-
Replay movie dialog - Stop movie at frame x feature - fixed off by 1 error on the stop frame number
-
Hex Editor - changed ROM values again dsiplay as red, saved in the config as RomFreezeColor
-
Fixed bug in memory watch that would make the first watch value drawn in the wrong place if watch file was full
-
Debugger - Step type functions now update other dialogs such as ppu, nametable, code/data, trace logger, etc.
-
"Disable screen saver" gui option now also diables the monitor powersave
-
Recent menus - no longer crash if item no longer exists, instead it ask the user if they want to remove the item from the list
-
Sound Config Dialog - When sound is off, all controls are grayed out
-
Memory Watch - fixed a regression made in 2.0.1 that broke the Save As menu item
-
Memory Watch - save menu item is grayed if file hasn't changed
+
Added experimental $2004 reading support to play micro machines with (little) shakes, and fixed some timing in the new PPU.
+
Added palette reading cases for the new PPU.
-
-
-
GUI/Enhancements
+
+
Win32
+
+
Minor Bug fixes
-
Last save slot used is stored in the config file
-
Made fullscreen toggle (Alt+Enter) remappable
-
Hex editor - Reverted fixedFontHeight to 13 instead of 14. Gave the option of adjusting the height by modifying RowHeightBorder in the .cfg file
-
Hex Editor - allowed the user to customize the color scheme by use of RGB values stored in the .cfg file
-
Hex editor - freeze/unfreeze ram addresses now causes the colors to update immediately, but only with groups of addresses highlighted at once (single ones still don't yet update)
-
Hex Editor - Save Rom As... menu option enabled and implemented
-
Window caption shows the name of the ROM loaded
-
Recent Movie Menu added
-
Load Last Movie context menu item added
-
Save Movie As... context menu item (for when a movie is loaded in read+write mode)
-
Drag & Drop support for all files related to FCEUX including:
+
Replay movie dialog - Stop movie at frame x feature - fixed off by 1 error on the stop frame number
+
Hex Editor - changed ROM values again dsiplay as red, saved in the config as RomFreezeColor
+
Fixed bug in memory watch that would make the first watch value drawn in the wrong place if watch file was full
+
Debugger - Step type functions now update other dialogs such as ppu, nametable, code/data, trace logger, etc.
+
"Disable screen saver" gui option now also diables the monitor powersave
+
Recent menus - no longer crash if item no longer exists, instead it ask the user if they want to remove the item from the list
+
Sound Config Dialog - When sound is off, all controls are grayed out
+
Memory Watch - fixed a regression made in 2.0.1 that broke the Save As menu item
+
Memory Watch - save menu item is grayed if file hasn't changed
-
.fcm (autoconverts to .fm2 and begins movie playback)
-
Savestates
-
Palette files (.pal)
+
+
+
GUI/Enhancements
-
Commandline - -palette commandline option
-
Memory Watch - option to bind to main window, if checked it gives GENS dialog style control, where there is no extra task bar item, and it minimizes when FCEUX is minimized
+
Last save slot used is stored in the config file
+
Made fullscreen toggle (Alt+Enter) remappable
+
Hex editor - Reverted fixedFontHeight to 13 instead of 14. Gave the option of adjusting the height by modifying RowHeightBorder in the .cfg file
+
Hex Editor - allowed the user to customize the color scheme by use of RGB values stored in the .cfg file
+
Hex editor - freeze/unfreeze ram addresses now causes the colors to update immediately, but only with groups of addresses highlighted at once (single ones still don't yet update)
+
Hex Editor - Save Rom As... menu option enabled and implemented
+
Window caption shows the name of the ROM loaded
+
Recent Movie Menu added
+
Load Last Movie context menu item added
+
Save Movie As... context menu item (for when a movie is loaded in read+write mode)
+
Drag & Drop support for all files related to FCEUX including:
-
-
SDL
-
+
.fcm (autoconverts to .fm2 and begins movie playback)
+
Savestates
+
Palette files (.pal)
-
added --subtitles
-
fixed Four Score movie playback
-
added --ripsubs for converting fm2 movie subtitles to an srt file
-
Lua is optional again, fixed the real issue
-
Lua is NO longer optional, so the SConscripts have been updated to reflect that change. This fixes the mysterious non-working input issue.
-
implemented saving/loading a savestate from a specific file on Alt+S/L
-
implemented starting an FM2 movie on Alt+R
-
added --pauseframe to pause movie playback on frame x
-
dropped UTFConverter.c from SDL build
-
added hotkey Q for toggling read-only/read+write movie playback
+
Commandline - -palette commandline option
+
Memory Watch - option to bind to main window, if checked it gives GENS dialog style control, where there is no extra task bar item, and it minimizes when FCEUX is minimized
-
-
-
-
+
+
SDL
+
+
+
added --subtitles
+
fixed Four Score movie playback
+
added --ripsubs for converting fm2 movie subtitles to an srt file
+
Lua is optional again, fixed the real issue
+
Lua is NO longer optional, so the SConscripts have been updated to reflect that change. This fixes the mysterious non-working input issue.
+
implemented saving/loading a savestate from a specific file on Alt+S/L
+
implemented starting an FM2 movie on Alt+R
+
added --pauseframe to pause movie playback on frame x
+
dropped UTFConverter.c from SDL build
+
added hotkey Q for toggling read-only/read+write movie playback
The 2.1.2 release fixes some bugs of 2.1.0a, increases game compatibility, launches a new PPU core, and adds usability enhancements to the windows port.
-
-
Common
+
The 2.1.2 release fixes some bugs of 2.1.0a, increases game compatibility, launches a new PPU core, and adds usability enhancements to the windows port.
+
+
Common
-
New PPU is now functional! You can access it by changing the newPPU flag in the config file. Windows users can access it from Config > PPU > New PPU
-
Dragon Ball Z 3 now playable again
-
Fixed action 52 game that was broken in post-FCEUX 2.0.3 versions
-
Mapper 253 mostly implemented
-
Mapper 43 fixed bug
+
New PPU is now functional! You can access it by changing the newPPU flag in the config file. Windows users can access it from Config > PPU > New PPU
+
Dragon Ball Z 3 now playable again
+
Fixed action 52 game that was broken in post-FCEUX 2.0.3 versions
+
Mapper 253 mostly implemented
+
Mapper 43 fixed bug
+
+
+
Win32
+
+
+
Imported NSF features from FCEUXDSP-NSF. Debugging tools are now compatible with NSF files.
+
Movies now record FDS disk swapping commands
+
Movie play dialog displays movie time based on ~60.1 (~50.1 PAL) instead of 60 & 50
+
Ram Watch and Ram Search dialogs imported from GENS rerecording
+
Ram Filter dialog removed (now redundant compared to both cheat search and ram search)
+
Lua script window ported from GENS
+
Fix for the directory overrides bug that caused overrides to reset
+
Debugger: .deb file saving/loading restored
+
"Save config file" menu item
+
"New PPU" menu item
-
Win32
-
+
Minor Bug fixes
+
-
Imported NSF features from FCEUXDSP-NSF. Debugging tools are now compatible with NSF files.
-
Movies now record FDS disk swapping commands
-
Movie play dialog displays movie time based on ~60.1 (~50.1 PAL) instead of 60 & 50
-
Ram Watch and Ram Search dialogs imported from GENS rerecording
-
Ram Filter dialog removed (now redundant compared to both cheat search and ram search)
-
Lua script window ported from GENS
-
Fix for the directory overrides bug that caused overrides to reset
-
Debugger: .deb file saving/loading restored
-
"Save config file" menu item
-
"New PPU" menu item
+
Minor fixes to recent menus
+
Fixed a bug that prevented the Map Hotkeys dialog's X button from closing the dialog
+
Restored DPCM Logging when Code/Data Logger is active
+
Memory watch - Save Changes Prompt - clicking save will default to quicksave first and save as 2nd (instead of always defaulting to save as)
+
Made Trace Logger refresh adequately when using stepping options in the debugger.
-
-
Minor Bug fixes
-
+
+
Lua
-
Minor fixes to recent menus
-
Fixed a bug that prevented the Map Hotkeys dialog's X button from closing the dialog
-
Restored DPCM Logging when Code/Data Logger is active
-
Memory watch - Save Changes Prompt - clicking save will default to quicksave first and save as 2nd (instead of always defaulting to save as)
-
Made Trace Logger refresh adequately when using stepping options in the debugger.
+
joypad.set() fixed. True,False, and Nil now work properly for all buttons. In addition there is a new "invert" option.
The 2.1.3 release fixes some bugs of 2.1.2, increases game compatibility, and adds usability enhancements to the windows port and adds a GUI to the SDL port.
-
-
Common
+
The 2.1.3 release fixes some bugs of 2.1.2, increases game compatibility, and adds usability enhancements to the windows port and adds a GUI to the SDL port.
+
+
Common
-
Fixed mappers 82, 25, 21, and 18. Games such as SD Kiji Blader, Ganbare Goemon Gaiden, and Ganbare Goemon Gaiden 2, Jajamaru Gekimadden are now playable
-
Fixes for mappers 253 & 226 - fixes games such as Fire Emblem (J) and Fire Emblem Gaiden (J)
-
Fix crashing on game loading for any battery backed ROMs with mappers from MapInitTab (fixes Esper Dream 2 - Aratanaru Tatakai (J)
-
FDS - show name of missing bios file in error message
-
NewPPU - fixed sprite hit before 255 and for non transparent hits only, thanks to dwedit for providing the fix
-
.fm2 file format header now has an FDS flag
+
Fixed mappers 82, 25, 21, and 18. Games such as SD Kiji Blader, Ganbare Goemon Gaiden, and Ganbare Goemon Gaiden 2, Jajamaru Gekimadden are now playable
+
Fixes for mappers 253 & 226 - fixes games such as Fire Emblem (J) and Fire Emblem Gaiden (J)
+
Fix crashing on game loading for any battery backed ROMs with mappers from MapInitTab (fixes Esper Dream 2 - Aratanaru Tatakai (J)
+
FDS - show name of missing bios file in error message
+
NewPPU - fixed sprite hit before 255 and for non transparent hits only, thanks to dwedit for providing the fix
+
.fm2 file format header now has an FDS flag
+
+
+
SDL
+
+
+
A GUI! A graphic user interface (using GTK) with many basic menu options
+
ported to SDL 1.3; compatibility maintained with 1.2
+
unix netplay is now functional; gtk network gui created
+
now prints the name of the mapper on ROM load
+
fixed dpad/joyhat support
+
VS unisystem keys now configable
+
changed default hotkeys and keys to match Win32
+
disallow --inputcfg gamepad0 and gamepad5
-
SDL
-
+
Win32
+
-
A GUI! A graphic user interface (using GTK) with many basic menu options
-
ported to SDL 1.3; compatibility maintained with 1.2
-
unix netplay is now functional; gtk network gui created
-
now prints the name of the mapper on ROM load
-
fixed dpad/joyhat support
-
VS unisystem keys now configable
-
changed default hotkeys and keys to match Win32
-
disallow --inputcfg gamepad0 and gamepad5
+
Made savestate backups optional (config - enable - backup savestates)
+
Made savestate compression togglable (config - enable - compress savestates)
+
Cheats dialog - Pause while active checkbox
+
Cheats dialog - Toggling a cheat in the cheats list now updates the active cheats count
+
Debugger - added an auto-load feature
+
Debugger - Fix so it doesn't crash if unminimized with no game loaded
+
Closing minimized windows no longer moves them the next time they get opened
+
Lua console - added a menu
+
Lua console - filename updates when lua scripts are dragged to emulator or recent filenames invoked
+
Name Table Viewer - Fix for use with New PPU
+
Trace Logger - Trace logger now logs the values of the stack pointer register
+
If a .fm2 file is drag and dropped with no ROM load, the open ROM dialog will appear
+
disable movie messages menu item
+
Added more window positions bounds checks. Accounts for -32000 positions and less out-of-range too
New lua functions: gui.parsecolor(), joypad.getup(), joypad.getdown(), emu.emulating()
+
Change gui.line, gui.box, joypad.get to function consistently with other lua emulators such as GENS rerecording
+
fixed zapper.read() to read movie data if a movie is playing. Also changed the struct values to x,y,fire. This breaks lua scripts that used it previous, sorry
+
gui.text() now has out of bounds checking
+
Lua no longer unpauses the emulator when a script is loaded
-
-
Lua
-
-
New lua functions: gui.parsecolor(), joypad.getup(), joypad.getdown(), emu.emulating()
-
Change gui.line, gui.box, joypad.get to function consistently with other lua emulators such as GENS rerecording
-
fixed zapper.read() to read movie data if a movie is playing. Also changed the struct values to x,y,fire. This breaks lua scripts that used it previous, sorry
-
gui.text() now has out of bounds checking
-
Lua no longer unpauses the emulator when a script is loaded
The 2.1.4 release fixes many bugs and adds new features compared to 2.1.3. In addition it also fixes up the movie code significantly; fixing implementation problems, loading speed, adding new features, and fixing bugs.
-
-
Common
+
The 2.1.4 release fixes many bugs and adds new features compared to 2.1.3. In addition it also fixes up the movie code significantly; fixing implementation problems, loading speed, adding new features, and fixing bugs.
+
+
Common
-
Added microphone support option. When enabled, Port 2 Start activates the Microphone
-
Prevent .zip files containing no recognized files from causing crash
-
Autohold - Added player 3 and 4 to autohold notification window, labeled controller input
-
mapper 19 savestate fix mirroring for "Dream Master (J)" corrected to "four-screen" by CRC check
-
Disable auto-savestates during turbo
-
Fixed so Gotcha! auto-enables the zapper
-
Autohold - Added player 3 and 4 to autohold notification window, labeled controller input
+
Added microphone support option. When enabled, Port 2 Start activates the Microphone
+
Prevent .zip files containing no recognized files from causing crash
+
Autohold - Added player 3 and 4 to autohold notification window, labeled controller input
+
mapper 19 savestate fix mirroring for "Dream Master (J)" corrected to "four-screen" by CRC check
+
Disable auto-savestates during turbo
+
Fixed so Gotcha! auto-enables the zapper
+
Autohold - Added player 3 and 4 to autohold notification window, labeled controller input
+
+
+
Movies
+
+
+
Fully implemented "bulletproof" read-only
+
Movie code now fully conforms to the Savestate section of the Laws of TAS
+
Fixed a potential desync that plays out an extra frame without an update to the frame count involving heavy lua use, joypad.get, and a loadstate
+
Movie support for microphone
+
Movies now have a "finished" mode. If a playback stops the movie isn't cleared from memory, and can be replayed or a state loaded Similar functionality as DeSmuME and GENS rerecording
+
New PPU flag in movie headers (doesn't change an emulators PPU state when loading a movie)
+
Much faster movie loading and movie-savestate loading
+
Made gamepad 2 off by default (so less movies should have unused player 2 data)
+
Implemented a "full savestate-movie load" mode similar to the implementation in VBA-rr and SNES9x-rr. In this mode loading a savestate in read+write doesn't truncate the movie to its frame count immediately. Instead it waits until input is recording into the movie (next frame). For win32 this feature is togglable in movie options and the context menu. For SDL this is off by default and a toggle will need to be added
+
Movie + loadstate errors are handled more gracefully now, with more informative error messages and the movie doesn't have to stop if backups are enabled
+
Fix PlayMovieFromBeginning when using a movie that starts from savestate
-
Movies
-
+
Lua
-
Fully implemented "bulletproof" read-only
-
Movie code now fully conforms to the Savestate section of the Laws of TAS
-
Fixed a potential desync that plays out an extra frame without an update to the frame count involving heavy lua use, joypad.get, and a loadstate
-
Movie support for microphone
-
Movies now have a "finished" mode. If a playback stops the movie isn't cleared from memory, and can be replayed or a state loaded Similar functionality as DeSmuME and GENS rerecording
-
New PPU flag in movie headers (doesn't change an emulators PPU state when loading a movie)
-
Much faster movie loading and movie-savestate loading
-
Made gamepad 2 off by default (so less movies should have unused player 2 data)
-
Implemented a "full savestate-movie load" mode similar to the implementation in VBA-rr and SNES9x-rr. In this mode loading a savestate in read+write doesn't truncate the movie to its frame count immediately. Instead it waits until input is recording into the movie (next frame). For win32 this feature is togglable in movie options and the context menu. For SDL this is off by default and a toggle will need to be added
-
Movie + loadstate errors are handled more gracefully now, with more informative error messages and the movie doesn't have to stop if backups are enabled
-
Fix PlayMovieFromBeginning when using a movie that starts from savestate
+
fix bug that caused zapper.read() to crash when movie playback ends
+
Win32 - Added option for palette selection as color for LUA colors. Included is a LUA script to display all choices with the value used to pick displayed color
-
-
Lua
+
+
New Lua functions
-
fix bug that caused zapper.read() to crash when movie playback ends
-
Win32 - Added option for palette selection as color for LUA colors. Included is a LUA script to display all choices with the value used to pick displayed color
+
movie.ispoweron()
+
movie.isfromsavestate()
+
emu.addgamegenie()
+
emu.delgamegenie()
+
savestate.object() which is savestate.create() with intuitive numbering under windows
+
gui.getpixel() which gets any gui.pixel() set pixel colors, and possibly other functions
+
emu.getscreenpixel() which gets the RGB and Palette of any pixel on the screen
+
lua function movie.getfilename() which returns the current movie filename without the path included
-
-
New Lua functions
+
+
Input Display
-
movie.ispoweron()
-
movie.isfromsavestate()
-
emu.addgamegenie()
-
emu.delgamegenie()
-
savestate.object() which is savestate.create() with intuitive numbering under windows
-
gui.getpixel() which gets any gui.pixel() set pixel colors, and possibly other functions
-
emu.getscreenpixel() which gets the RGB and Palette of any pixel on the screen
-
lua function movie.getfilename() which returns the current movie filename without the path included
+
Input display updates on loadstate
+
Input display overhaul that uses different colors for different input contexts
+
Input display now shows both currently pressed buttons and buttons held the previous frame
-
-
Input Display
+
+
Win32
-
Input display updates on loadstate
-
Input display overhaul that uses different colors for different input contexts
-
Input display now shows both currently pressed buttons and buttons held the previous frame
+
Added NTSC 2x scalar option with some CFG config options of it's own Added Ram Search hotkeys for the first 6 search types in the list
+
Add Cheat buttons for Ram Search and Ram Watch
+
With special scaler in window mode, it's possible to resize to anything above the minimum.
+
Recording a new movie adds it to recent movies list
+
Replay dialog, when selecting a movie in a relative path (.\movies for example), the recent movies list stores an absolute path instead
+
Replay dialog shows PAL flag and New PPU flags
+
CDLogger - fixed bug preventing correct interrupt vectors from logging
+
Memwatch - ignore spaces at the beginnign of an address in the address boxes
+
Replay dialog - fix bug that was causing it to always report savestate movies as soft-reset
-
-
Win32
+
+
Debugger
+
-
Added NTSC 2x scalar option with some CFG config options of it's own Added Ram Search hotkeys for the first 6 search types in the list
-
Add Cheat buttons for Ram Search and Ram Watch
-
With special scaler in window mode, it's possible to resize to anything above the minimum.
-
Recording a new movie adds it to recent movies list
-
Replay dialog, when selecting a movie in a relative path (.\movies for example), the recent movies list stores an absolute path instead
-
Replay dialog shows PAL flag and New PPU flags
-
CDLogger - fixed bug preventing correct interrupt vectors from logging
-
Memwatch - ignore spaces at the beginnign of an address in the address boxes
-
Replay dialog - fix bug that was causing it to always report savestate movies as soft-reset
+
Added conditional debugging option 'K', for bank PC is on
+
Fixed bug involving pausing emulation outside of the debugger, then trying to use the debugger commands, and having the CPU registers become corrupted
+
Made debugger able to break on and distinguish Stack reads/writes
-
-
Debugger
-
+
+
Hex Editor
+
-
Added conditional debugging option 'K', for bank PC is on
-
Fixed bug involving pausing emulation outside of the debugger, then trying to use the debugger commands, and having the CPU registers become corrupted
-
Made debugger able to break on and distinguish Stack reads/writes
+
Added "Goto" command
+
Made the Hex Editor display the Frozen, Bookmarked, etc. status of the selected address, and made the Frozen color override the Bookmarked color.
-
-
Hex Editor
-
+
+
Cheat Search
+
-
Added "Goto" command
-
Made the Hex Editor display the Frozen, Bookmarked, etc. status of the selected address, and made the Frozen color override the Bookmarked color.
+
Made enabling/disabling cheats no longer deselect the selected cheat
+
Added context menu to Cheat Dialog Cheat Listbox, populated list with Toggle Cheat, Poke Cheat Value, and Goto In Hex Editor
+
Enabled multi-select for Cheat menu to allow multiple toggles and deletes
+
Made cheat menu's Pause When Active effect immediate
-
-
Cheat Search
-
+
+
GUI
+
-
Made enabling/disabling cheats no longer deselect the selected cheat
-
Added context menu to Cheat Dialog Cheat Listbox, populated list with Toggle Cheat, Poke Cheat Value, and Goto In Hex Editor
-
Enabled multi-select for Cheat menu to allow multiple toggles and deletes
-
Made cheat menu's Pause When Active effect immediate
+
Added Tools - GUI option to partially disable visual themes, so the emulator can be made to look like it did in 2.1.1 and earlier releases. Drag & Drop - if dropping a .fcm with no ROM loaded, prompt for one (same functionality that was added to .fm2 files)
+
Added single-instance mode, which makes starting a second copy of FCEUX load the file into the first, then exit.Mode off by default, togglable under Config - GUI
-
-
GUI
-
-
-
Added Tools - GUI option to partially disable visual themes, so the emulator can be made to look like it did in 2.1.1 and earlier releases. Drag & Drop - if dropping a .fcm with no ROM loaded, prompt for one (same functionality that was added to .fm2 files)
-
Added single-instance mode, which makes starting a second copy of FCEUX load the file into the first, then exit.Mode off by default, togglable under Config - GUI
The 2.1.5 release fixes a lot of bugs and brings various improvements to the prior 2.1.4a release. In addition, the SDL port has improved signficantly; completely overhauling the GTK2 GUI, fixing many sound issues, and fixing a variety of bugs.
-
Common
+
Common
-
Fixed compatibility issue with Young Indiana Jones Chronicles
-
Fixed bug in new PPU that made some intensify bits not get applied to output (fixed flashing siren screen in Werefolf)
-
Fix many segmentation faults related to file handling
+
Fixed compatibility issue with Young Indiana Jones Chronicles
+
Fixed bug in new PPU that made some intensify bits not get applied to output (fixed flashing siren screen in Werefolf)
+
Fix many segmentation faults related to file handling
+
+
+
Movies
+
+
+
Slight performance increase when loading movies
+
Fixed read-only loadstate error messages and logic
-
Movies
-
+
Lua
-
Slight performance increase when loading movies
-
Fixed read-only loadstate error messages and logic
+
Lua socket added to built-in lua library
+
Fixed speed.mode() function so that normal turns off turbo
-
-
Lua
+
+
New Lua functions
-
Lua socket added to built-in lua library
-
Fixed speed.mode() function so that normal turns off turbo
+
gui.savescreenshotas()
+
sound.get()
-
-
New Lua functions
+
+
Win32
-
gui.savescreenshotas()
-
sound.get()
+
Fixed bug where PPU toggling toggled the Game Genie as well
+
Fixed some minor GUI issues
+
Added avi capture commandline argument and related parameters
+
Fix input selection for Famicom Expansion port
-
-
Win32
+
+
Debugger
+
-
Fixed bug where PPU toggling toggled the Game Genie as well
-
Fixed some minor GUI issues
-
Added avi capture commandline argument and related parameters
-
Fix input selection for Famicom Expansion port
+
Fixed Ram Search to only display valid RAM addresses (0000-07FF and 6000-7FFF)
+
Fixed crash when re-opening debugging window
-
-
Debugger
-
+
+
Hex Editor
+
-
Fixed Ram Search to only display valid RAM addresses (0000-07FF and 6000-7FFF)
-
Fixed crash when re-opening debugging window
+
Added a confirmation prompt before removing all bookmarks
-
-
Hex Editor
-
+
+
Ram Watch / Ram Search
+
-
Added a confirmation prompt before removing all bookmarks
+
Fixed the multiple selection of watches
+
Added support for Multiple selection of addresses in RamWatch Fixed issue with restoration of the selection range in RamWatch
-
-
Ram Watch / Ram Search
-
+
+
TasEdit
+
-
Fixed the multiple selection of watches
-
Added support for Multiple selection of addresses in RamWatch Fixed issue with restoration of the selection range in RamWatch
+
General cleanup
+
Fixed crash when truncating while turbo was enabled
+
Invalidate greenzone when re-recording earlier portions of a movie
-
-
TasEdit
-
+
+
GUI
+
-
General cleanup
-
Fixed crash when truncating while turbo was enabled
-
Invalidate greenzone when re-recording earlier portions of a movie
The 2.2.0 release fixes a lot of bugs and adds many new features to prior releases, increasing game compatibility and enhancing usability of both Windows and SDL ports. The Windows version also includes major improvement of debugging tools and introduces the new powerful toolset – TAS Editor v1.0 – created to boost efficiency and ease of Tool-Assisted Speedrunning.
-
-
Common
+
The 2.2.0 release fixes a lot of bugs and adds many new features to prior releases, increasing game compatibility and enhancing usability of both Windows and SDL ports. The Windows version also includes major improvement of debugging tools and introduces the new powerful toolset – TAS Editor v1.0 – created to boost efficiency and ease of Tool-Assisted Speedrunning.
+
+
Common
-
Fixed crash when using machine with no sound card
-
Fixed long savestate messages containing path
-
Soft reset and power switch messages
-
All onscreen messages are now logged to Message Log
-
Fixed wrong default palette entry
-
Fixed bug when loading UNIF games
-
Improved HUD text rendering wrapping
-
"Display FPS" option
+
Fixed crash when using machine with no sound card
+
Fixed long savestate messages containing path
+
Soft reset and power switch messages
+
All onscreen messages are now logged to Message Log
+
Fixed wrong default palette entry
+
Fixed bug when loading UNIF games
+
Improved HUD text rendering wrapping
+
"Display FPS" option
+
+
+
Emulation
+
+
PAL/NTSC noise channel bug fixed
+
All latest mapper changes from fceu-mm
+
Also added mappers 176, 116, 156, 252, 28
+
Fixed mappers 242, 227, 115, 248, 12, 164, 15, 253, 23, 178, 90, 73 and many others
+
Straighten out bandai m159/m016 handling and add valid null-EEPROM emulation to get those games booting.
+
Add ability for CNROM games to choose whether they have bus conflicts (fixes Colorful Dragon (Unl) (Sachen), since it flakes out if bus conflicts are emulated)
+
Fixed bus conflict emulation, no kage no densetsu bug anymore
+
Fixed newppu bug which prevented metroid from booting, CHR RAM was not getting initialized to anything
+
Newppu - fix bug in scroll reg logic causing mis-scrolls in p'radikus conflict
+
+
+
Movies
+
+
Fixed old bug in "Play Movie From Beginning"
+
Fixed replay engine bug that doubles the last input of the movie
+
Fixed movie savestates logic, loading post-movie savestates from different timeline is not allowed in read-only
+
Fixed savestates filenaming bug when working with a movie
+
Added support for HUD recording in AVI dumping
+
Rerecords counter display
+
Config->Movie options->Always suggest Read-Only replay (for Replay dialog). No more accidental rewrites!
+
Removed "Lag Counter Reset" hotkey, as it was obsolete since FCEUX 2.0.2
+
+
+
Lua
+
+
Fixed lua drawing alpha blending
+
Auto-clearing previous frame drawings (same behaviour as other emulators)
+
New library: taseditor (Windows-only) - contains 24 functions, see taseditor.chm
-
Emulation
+
New Lua functions:
-
PAL/NTSC noise channel bug fixed
-
All latest mapper changes from fceu-mm
-
Also added mappers 176, 116, 156, 252, 28
-
Fixed mappers 242, 227, 115, 248, 12, 164, 15, 253, 23, 178, 90, 73 and many others
-
Straighten out bandai m159/m016 handling and add valid null-EEPROM emulation to get those games booting.
-
Add ability for CNROM games to choose whether they have bus conflicts (fixes Colorful Dragon (Unl) (Sachen), since it flakes out if bus conflicts are emulated)
-
Fixed bus conflict emulation, no kage no densetsu bug anymore
-
Fixed newppu bug which prevented metroid from booting, CHR RAM was not getting initialized to anything
-
Newppu - fix bug in scroll reg logic causing mis-scrolls in p'radikus conflict
+
emu.paused()
+
emu.setlagflag()
+
joypad.getimmediate()
-
Movies
+
New scripts:
-
Fixed old bug in "Play Movie From Beginning"
-
Fixed replay engine bug that doubles the last input of the movie
-
Fixed movie savestates logic, loading post-movie savestates from different timeline is not allowed in read-only
-
Fixed savestates filenaming bug when working with a movie
-
Added support for HUD recording in AVI dumping
-
Rerecords counter display
-
Config->Movie options->Always suggest Read-Only replay (for Replay dialog). No more accidental rewrites!
-
Removed "Lag Counter Reset" hotkey, as it was obsolete since FCEUX 2.0.2
+
BoulderDash_AmoebaAI.lua
+
ButtonCount.lua
+
CustomLagIndicator_RvT.lua
+
RBIBaseball.lua
+
SoundDisplay.lua
+
SoundDisplay2.lua
+
taseditor\InputDisplay_for_Selection.lua
+
taseditor\InvertSelection.lua
+
taseditor\RecordBackwards.lua
+
taseditor\ShowNotes.lua
+
taseditor\Swap1P2P.lua
+
taseditor\TrackNoise.lua
+
+
+
Win32
+
+
Total revamp of fulscreen support
+
Fixed graphic tearing with vertical sync enabled
+
Added "Maintain aspect ratio" option to Video config
+
Added "Hide mouse cursor" and "Use console BG color for empty areas" options to Video config
+
Added "Switch fullscreen by double-click" option to GUI config
+
Added "Force Grayscale" option to Palette config
+
Fixed crashes and bugs caused by 2.1.5 allowing hotkeys without ROM loaded
+
Lua console now gets proper file path when selecting a file from the recent menu
+
Fixed context menus to use rightclicks in context menus correctly
+
Reload hotkey now also supports removing invalid filenames in Recent ROMs
+
Replay dialog speedup, it doesn't search for movies in fceux root folder anymore
+
Support multibyte languages for opening files through drag&drop (except for Lua files)
+
Loading TAS Editor projects (*.fm3) by drag&drop
+
Fixed bug with Input Config not displaying some key names
+
Launch tools hotkeys shown in menu; general cleanup of menu/settings, changed some checkboxes to radiobuttons
+
Added "Clear" button to Message Log
+
+
+
TAS Editor
+
+
Completely rewritten tool with brand new architecture and design. Too many changes to enlist, see taseditor.chm
+
+
+
Debugger
+
+
General window layout cleanup; different font; ".DEB files" can be switched off; etc
+
Deleting a breakpoint/bookmark leaves selection in the list
+
Fixed mysterious out of bounds condition while editing breakpoints
+
Fixed RAM peek by a rightclick on left pane
+
Allow Frame Advancing when Debugger is in breakpoint state
+
Disabled breakpoints now don't impose slowdown
+
When a breakpoint is hit, it becomes highlighed (selected) in the breakpoints list
+
Show the number of breakpoints (enabled and total) above the breakpoints list
+
">" points at current line in disassembly
+
Improved stack display
+
Added "CPU cycles" and "Instructions" counters (cumulative and delta)
+
Added "Cycles counter exceeds N" and "Instructions counter exceeds N" type of breakpoints
+
Single click on any address copies this address to the "Seek To" field and "Bookmark Add" field
+
Double-click on any address prompts "Add Breakpoint here" dialog
+
"ROM offsets" option displays real ROM addresses in the Disassembly window
+
Fixed conditional breakpoints bug: the error message didn't appear when editing a breakpoint
+
Fixed and improved Symbolic debug (Names and Comments display)
+
Added Bookmarks naming
+
Cleaned up and vastly improved debugging documentation
+
+
+
Trace Logger
+
+
Added "Symbolic trace" option
+
"RTS" instructions now output the subroutine address/name
+
Added "Use Stack Pointer for code tabbing (nesting visualization)" option
+
Added "To the left from disassembly text" option for log format customization
+
Added "Log current Frame number" option
+
Added "Log emulator messages" option
+
Added "Log breakpoint hits" option
+
Fixed bug with trying to log to file without choosing a filename
+
Tracer now also updates its window when user pauses the game, not just when Debugger snaps
The 2.2.1 release fixes many bugs and adds a couple of new features. The most notable feature is "Auto-resume old play session", which is similar to "Suspending Play". Enable this option in the Config menu and now you can close ROMs or emulator anytime, next time the game state will be resumed from the closing point.
-
-
Common
+
+
Common
-
Speed up HUD text drawing
+
Speed up HUD text drawing
+
+
+
Emulation
+
+
Finished mappers to boards conversion
+
Fixed mappers 99, 228, 18, 198, 24, 26, 69, 19
+
Mapper 115 - redesign according to the hardware tests
+
Fixed "you ling xing dong" by assigning to mapper 192
+
Fixed crash when four-screen bit is set after CRC check
+
UNIF: verbose/safe chunk loading, fixes some crashes
+
+
+
Lua
+
+
removed "shadow pixels" from gui.text()
-
Emulation
+
New Lua functions:
-
Finished mappers to boards conversion
-
Fixed mappers 99, 228, 18, 198, 24, 26, 69, 19
-
Mapper 115 - redesign according to the hardware tests
-
Fixed "you ling xing dong" by assigning to mapper 192
-
Fixed crash when four-screen bit is set after CRC check
-
UNIF: verbose/safe chunk loading, fixes some crashes
+
gui.parsecolor()
-
Lua
+
New scripts:
-
removed "shadow pixels" from gui.text()
+
JumpingFCEUXWindow.lua
-
-
New Lua functions:
+
+
Win32
-
gui.parsecolor()
+
Fixed "Enter New Input" dialog (Hotkeys mapping)
+
Fixed zapper and mouse positioning in fullscreen
+
Remodel "Video config" dialog
+
Added "TV Aspect (4:3)"
+
Holding Shift when resizing FCEUX window inverts "Force integral factors" meaning
+
Fixed window regions redrawing
+
Added the option to define custom emulation speed (NES->Emulation Speed->Set Custom Speed)
+
Now Frame Advance timings (initial delay and speed) can be tweaked by user
+
Added Config->Enable->Auto-resume old play session
+
Moved "Config->Game Genie" to "Config->Enable->Game Genie ROM"
+
Play movie dialog shows New PPU in red if the required setting does not match
+
Fixed NameTable Viewer crash when the corresponding nametable RAM is not available on the cart
+
The number of active cheats is displayed on screen when a ROM is loaded
+
PPU/PAL/Input type changing is disabled when a movie is playing
-
-
New scripts:
+
+
TAS Editor
-
JumpingFCEUXWindow.lua
+
Fixed keyboard accelerators when editing Notes
+
Fixed Greenzone saving while emulator is unpaused
+
Fixed drawing bugs when the Playback cursor moves more than once within one update
+
Changed "Compact save" dialog, added 4 options of Greenzone saving
+
Added "Config->Project file saving options"
+
Changed "Follow cursor" logic, now the Piano Roll doesn't follow Playback cursor while seeking
+
No "Autopause at the end of the Movie" when Recording
+
Fixed bug when adding new item to History Log
+
Fixed Bookmarks List height on Windows 7
-
-
Win32
+
+
Trace Logger
-
Fixed "Enter New Input" dialog (Hotkeys mapping)
-
Fixed zapper and mouse positioning in fullscreen
-
Remodel "Video config" dialog
-
Added "TV Aspect (4:3)"
-
Holding Shift when resizing FCEUX window inverts "Force integral factors" meaning
-
Fixed window regions redrawing
-
Added the option to define custom emulation speed (NES->Emulation Speed->Set Custom Speed)
-
Now Frame Advance timings (initial delay and speed) can be tweaked by user
-
Added Config->Enable->Auto-resume old play session
-
Moved "Config->Game Genie" to "Config->Enable->Game Genie ROM"
-
Play movie dialog shows New PPU in red if the required setting does not match
-
Fixed NameTable Viewer crash when the corresponding nametable RAM is not available on the cart
-
The number of active cheats is displayed on screen when a ROM is loaded
-
PPU/PAL/Input type changing is disabled when a movie is playing
+
Fixed RAM-located code logging when CDLogger options are enabled
+
Fixed automatic window update when a breakpoint is hit
+
Fixed RTS padding
-
-
TAS Editor
+
+
Code/Data Logger
-
Fixed keyboard accelerators when editing Notes
-
Fixed Greenzone saving while emulator is unpaused
-
Fixed drawing bugs when the Playback cursor moves more than once within one update
-
Changed "Compact save" dialog, added 4 options of Greenzone saving
-
Added "Config->Project file saving options"
-
Changed "Follow cursor" logic, now the Piano Roll doesn't follow Playback cursor while seeking
-
No "Autopause at the end of the Movie" when Recording
-
Fixed bug when adding new item to History Log
-
Fixed Bookmarks List height on Windows 7
+
Added current CDL filename field and default CDL naming
+
Added "Auto-save .CDL when closing ROMs" option
+
Added "Auto-load .CDL when opening the window" option
+
Added "Auto-resume logging when loading ROMs" option
+
Improved CHR logging, now it also logs the data when using Old PPU
-
-
Trace Logger
+
+
Hex Editor
-
Fixed RAM-located code logging when CDLogger options are enabled
-
Fixed automatic window update when a breakpoint is hit
-
Fixed RTS padding
+
Show symbolic names in the window caption when "Symbolic debug" is enabled
+
Fixed crash when trying to save ROM to an invalid path
+
Fixed ROM coloring when using CDLogger data
-
-
Code/Data Logger
+
+
RAM Search
-
Added current CDL filename field and default CDL naming
-
Added "Auto-save .CDL when closing ROMs" option
-
Added "Auto-load .CDL when opening the window" option
-
Added "Auto-resume logging when loading ROMs" option
-
Improved CHR logging, now it also logs the data when using Old PPU
+
Added "Search ROM" option
-
-
Hex Editor
+
+
Cheats
-
Show symbolic names in the window caption when "Symbolic debug" is enabled
-
Fixed crash when trying to save ROM to an invalid path
-
Fixed ROM coloring when using CDLogger data
+
Added "Add from CHT file..." button
+
Update the list of cheats when ROM is changed
-
-
RAM Search
+
+
SDL
-
Added "Search ROM" option
+
Use desktop resolution for fullscreen by setting SDL.XResolution and SDL.YResolution to 0 (new default is 0)
+
Fixed bug where "quit" hotkey would do nothing in '--nogui' mode
+
Fixed fullscreen zapper issues
+
Display a message dialog on errors in addition to printing to stderr
+
Added "Options->Auto-Resume Play"
+
Fixed build issues on various versions of OS X
-
-
Cheats
-
-
Added "Add from CHT file..." button
-
Update the list of cheats when ROM is changed
-
-
-
SDL
-
-
Use desktop resolution for fullscreen by setting SDL.XResolution and SDL.YResolution to 0 (new default is 0)
-
Fixed bug where "quit" hotkey would do nothing in '--nogui' mode
-
Fixed fullscreen zapper issues
-
Display a message dialog on errors in addition to printing to stderr
The 2.2.3 release fixes a number of emulation bugs, features overclocking (for lag reduction) and Dendy mode, and adds support for a bunch of new ROM dumps (mostly unlicensed). Reverse engineering tools and Lua scripting have got some updates, new input devices are supported, new palette files have beed added. The SDL port has been fixed and updated as well.
Fixed a bug with FDS flag being always set when converting a FCM
-
-
Movies
+
+
Video
-
Fixed a bug with FDS flag being always set when converting a FCM
+
Prescale filter for 2x, 3x and 4x resolutions
+
Made NTSC filter internal resolution closer to 4:3
-
-
Video
+
+
Palette
-
Prescale filter for 2x, 3x and 4x resolutions
-
Made NTSC filter internal resolution closer to 4:3
-
-
-
Palette
-
-
Support 512 color palettes
+
Support 512 color palettes
Added external palettes: SONY_CXA2025AS_US.pal, RP2C03.pal (and its versions), Unsaturated-V6.pal
-
Option to swap deemphasis bits
+
Option to swap deemphasis bits
-
-
Sound
+
+
Sound
Option to swap duty cycles
-
NSF can be set to Dendy mode
-
-
-
Input
-
-
Fix Mouse input implementation
-
Support for SNES mouse
-
PEC-586 russian keyboard support
+
NSF can be set to Dendy mode
-
Lua
+
Input
-
Removed speed notification per script reload, if it remained 100%
-
Fixed lua drawings in NSF
-
Proper halo for lua font
-
Fixes to sound.get() region consistency and frequency/midikey detection for Noise and DPCM channels
+
Fix Mouse input implementation
+
Support for SNES mouse
+
PEC-586 russian keyboard support
-
-
New Lua functions:
+
+
Lua
-
emu.getpath()
-
emu.loadrom()
-
rom.writebyte()
-
gethash()
+
Removed speed notification per script reload, if it remained 100%
+
Fixed lua drawings in NSF
+
Proper halo for lua font
+
Fixes to sound.get() region consistency and frequency/midikey detection for Noise and DPCM channels
-
Win32
+
New Lua functions:
-
Added -dumpinput and -playinput functions
-
Support for SNES pad
-
Added onscreen messages when region changes
+
emu.getpath()
+
emu.loadrom()
+
rom.writebyte()
+
gethash()
-
-
Debugger
+
+
Win32
-
Added debuggerPageSize config variable which lets you pick whether 8KB physical PRG pages are used, or 16KB (the original). It defaults to 14 (1<<14 == 16KB).
-
Set symbolic debugger name entry dialog text limits when creating a new label
-
Fixed new-PPU debug information (address and pixel)
-
Step Into hotkey
-
More granular accounting of scanline and dot
+
Added -dumpinput and -playinput functions
+
Support for SNES pad
+
Added onscreen messages when region changes
-
-
Trace Logger
+
+
Debugger
-
Fixed incorrect display of resolved address for (FF,x)
+
Added debuggerPageSize config variable which lets you pick whether 8KB physical PRG pages are used, or 16KB (the original). It defaults to 14 (1<<14 == 16KB).
+
Set symbolic debugger name entry dialog text limits when creating a new label
+
Fixed new-PPU debug information (address and pixel)
+
Step Into hotkey
+
More granular accounting of scanline and dot
-
-
Symbolic debugging
+
+
Trace Logger
-
Optionally display register names
+
Fixed incorrect display of resolved address for (FF,x)
-
-
CDLogger
+
+
Symbolic debugging
-
Fix crash when attempting to open file picked as target for Save Stripped ROM operation
+
Optionally display register names
-
-
PPU Viewer
+
+
CDLogger
-
8x16 sprite display mode
+
Fix crash when attempting to open file picked as target for Save Stripped ROM operation
-
-
Hex Editor
+
+
PPU Viewer
-
Added option to dump entire 64k memory space
-
Don't forget to load the symbols, when hex editor is first launched before debugger
-
Show values for registers $4000-$4017
+
8x16 sprite display mode
-
-
Cheats
+
+
Hex Editor
-
mmc5 Akumajou Dracula crash fix
-
More RAM available in search
+
Added option to dump entire 64k memory space
+
Don't forget to load the symbols, when hex editor is first launched before debugger
+
Show values for registers $4000-$4017
-
-
SDL
+
+
Cheats
-
Added apply button to video config dialog
-
Added link to libgd project download page in readme
-
Noted optional libgd dependency in readme
-
SCons: Fixed logic for LOGO and CREATE_AVI options
-
Manpage updates
-
Added hotkeys for volume up/down
-
Menu toggling with the Alt key
-
Print error when opengl/scalers are both enabled
-
Fixed bug where lua open file gui would default to home directory
+
mmc5 Akumajou Dracula crash fix
+
More RAM available in search
-
-
-
-
+
+
SDL
+
+
Added apply button to video config dialog
+
Added link to libgd project download page in readme
+
Noted optional libgd dependency in readme
+
SCons: Fixed logic for LOGO and CREATE_AVI options
+
Manpage updates
+
Added hotkeys for volume up/down
+
Menu toggling with the Alt key
+
Print error when opengl/scalers are both enabled
+
Fixed bug where lua open file gui would default to home directory
The header is always in ASCII plain text format. It consists of several key-value pairs.
The input log section can be identified by it starting with a | (pipe).
The input log section can be either in ASCII plain text format or in binary format.
-
The input log section terminates at EOF, unless the length key is specified in header.
+
The input log section terminates at EOF, unless the length key is specified in header.
Newlines may be \r\n or \n.
@@ -217,54 +217,54 @@
Integer keys (also used for booleans, with a 1 for true and 0 for false) must have a value that can be stored as int32:
-
- version (required) - the version of the movie file format; for now it is always 3
-
-
- emuVersion (required) - the version of the emulator used to produce the movie
-
-
- rerecordCount (optional) - the rerecord count
-
-
- palFlag (bool) (optional) - true if the movie uses PAL timing
-
-
- NewPPU (bool) (optional) - true if the movie uses New PPU
-
-
- FDS (bool) (optional) - true if movie was recorded on a Famicom Disk System (FDS) game
-
-
- fourscore (bool) - true if a fourscore was used. If fourscore is not used, then port0 and port1 are required
-
-
- port0 - indicates the type of input device attached to the port 0. Supported values are:
+
- version (required) - the version of the movie file format; for now it is always 3
+
+
- emuVersion (required) - the version of the emulator used to produce the movie
+
+
- rerecordCount (optional) - the rerecord count
+
+
- palFlag (bool) (optional) - true if the movie uses PAL timing
+
+
- NewPPU (bool) (optional) - true if the movie uses New PPU
+
+
- FDS (bool) (optional) - true if movie was recorded on a Famicom Disk System (FDS) game
+
+
- fourscore (bool) - true if a fourscore was used. If fourscore is not used, then port0 and port1 are required
+
+
- port0 - indicates the type of input device attached to the port 0. Supported values are:
SI_NONE = 0
SI_GAMEPAD = 1
SI_ZAPPER = 2
-
-
- port1 - indicates the type of input device attached to the port 1. Supported values are:
+
+
- port1 - indicates the type of input device attached to the port 1. Supported values are:
SI_NONE = 0
SI_GAMEPAD = 1
SI_ZAPPER = 2
-
-
- port2 (required) - indicates the type of the FCExp port device which was attached. Supported values are:
+
+
- port2 (required) - indicates the type of the FCExp port device which was attached. Supported values are:
SIFC_NONE = 0
-
-
- binary (bool) (optional) - true if input log is stored in binary format
-
-
- length (optional) - movie size (number of frames in the input log). If this key is specified and the number is >= 0, the input log ends after specified number of records, and any remaining data should not be parsed. This key is used in fm3 format to allow storing extra data after the end of input log
+
+
- binary (bool) (optional) - true if input log is stored in binary format
+
+
- length (optional) - movie size (number of frames in the input log). If this key is specified and the number is >= 0, the input log ends after specified number of records, and any remaining data should not be parsed. This key is used in fm3 format to allow storing extra data after the end of input log
String keys have values that consist of the remainder of the key-value pair line. As a consequence, string values cannot contain newlines.
-
- romFilename (required) - the name of the file used to record the movie
-
-
- comment (optional) - simply a memo
+
- romFilename (required) - the name of the file used to record the movie
+
+
- comment (optional) - simply a memo
by convention, the first token in the comment value is the subject of the comment
by convention, subsequent comments with the same subject should have their ordering preserved and may be used to approximate multi-line comments
-
by convention, the author of the movie should be stored in comment(s) with a subject of: author
+
by convention, the author of the movie should be stored in comment(s) with a subject of: author
Example:
comment author adelikat
-
-
- subtitle (optional) - a message that will be displayed on screen when movie is played back (unless Subtitles are turned off, see Movie options)
+
+
- subtitle (optional) - a message that will be displayed on screen when movie is played back (unless Subtitles are turned off, see Movie options)
by convention, subtitles begin with the word "subtitle"
by convention, an integer value following the word "subtitle" indicates the frame that the subtitle will be displayed
@@ -275,13 +275,13 @@
subtitle 1000 Level Two
At frame 1000 the words "Level Two" will be displayed on the screen
-
-
- guid (required) - a unique identifier for a movie, generated when the movie is created, which is used when loading a savestate to make sure it belongs to the current movie
+
+
- guid (required) - a unique identifier for a movie, generated when the movie is created, which is used when loading a savestate to make sure it belongs to the current movie
GUID keys have a value which is in the standard guide format: 452DE2C3-EF43-2FA9-77AC-0677FC51543B
-
-
- romChecksum (required) - the base64 of the hexified MD5 hash of the ROM which was used to record the movie
-
-
- savestate (optional) - a fcs savestate blob, in case a movie was recorded from savestate
+
+
- romChecksum (required) - the base64 of the hexified MD5 hash of the ROM which was used to record the movie
+
+
- savestate (optional) - a fcs savestate blob, in case a movie was recorded from savestate
Hex string keys (used for binary blobs) have a value that is like 0x0123456789ABCDEF...
@@ -290,13 +290,13 @@
The input log section consists of movie records either in the form of text lines or in the form of binary data.
-
Text format (default format):
+
Text format (default format):
Every frame of the movie is represented by line of text beginning and ending with a | (pipe).
The fields in the line are as follows, except when fourscore is used.
-
|commands|port0|port1|port2|
+
|commands|port0|port1|port2|
-
Field commands is a variable length decimal integer which is interpreted as a bit field corresponding to miscellaneous input states which are valid at the start of the frame. Current values for this are:
+
Field commands is a variable length decimal integer which is interpreted as a bit field corresponding to miscellaneous input states which are valid at the start of the frame. Current values for this are:
1 = Soft Reset
2 = Hard Reset (Power)
@@ -311,31 +311,31 @@
the field consists of eight characters which constitute a bit field
any character other than ' ' or '.' means that the button was pressed
-
by convention, the following mnemonics are used in a column to remind us of which button corresponds to which column: RLDUTSBA (Right, Left, Down, Up, sTart, Select, B, A)
+
by convention, the following mnemonics are used in a column to remind us of which button corresponds to which column: RLDUTSBA (Right, Left, Down, Up, sTart, Select, B, A)
SI_ZAPPER:
-
XXX YYY B Q Z
+
XXX YYY B Q Z
-
XXX: %03d, the x position of the mouse
-
YYY: %03d, the y position of the mouse
-
B: %1d, 1 if the mouse button is pressed; 0 if not
-
Q: %1d, an internal value used by the emulator's zapper code
-
Z: %d, a variable-length decimal integer; an internal value used by the emulator's zapper code
+
XXX: %03d, the x position of the mouse
+
YYY: %03d, the y position of the mouse
+
B: %1d, 1 if the mouse button is pressed; 0 if not
+
Q: %1d, an internal value used by the emulator's zapper code
+
Z: %d, a variable-length decimal integer; an internal value used by the emulator's zapper code
SI_NONE:
the field must be empty
-
If a fourscore is used, then port0 and port1 are irrelevant and ignored.
+
If a fourscore is used, then port0 and port1 are irrelevant and ignored.
The input types must all be gamepads, and each input log record must be in the following format:
Every frame of the movie is represented by a record of a fixed length which can be determined by the devices on port0 and port1.
@@ -372,12 +372,12 @@
0 bytes added to the size of record
-
If a fourscore is used, then port0 and port1 are irrelevant and ignored. 4 bytes are added to the size of record. The bits of the 1st byte represent the state of buttons of the 1st joypad (bit0 = A, bit1 = B, bit2 = Select, bit3 = sTart, bit4 = Up, bit5 = Down, bit6 = Left, bit7 = Right); bits of the 2nd byte represent the state of buttons of the 2nd joypad, and so on.
+
If a fourscore is used, then port0 and port1 are irrelevant and ignored. 4 bytes are added to the size of record. The bits of the 1st byte represent the state of buttons of the 1st joypad (bit0 = A, bit1 = B, bit2 = Select, bit3 = sTart, bit4 = Up, bit5 = Down, bit6 = Left, bit7 = Right); bits of the 2nd byte represent the state of buttons of the 2nd joypad, and so on.
-
Notes:
-
+
Notes:
+
A. All movies start from power-on, unless a savestate key-value is present.