Two9A / jsGB

JavaScript emulation of the GameBoy console
http://imrannazar.com/
Other
728 stars 110 forks source link

code doesn't run #3

Open jnharton opened 9 years ago

jnharton commented 9 years ago

On initially downloading this the code does not seem to run at all. It appears that one possible issue is a minor typo in 'index.html'.

It looks like this:

<td class="regname">D</td><td class=reg" rel="d"></td>

There should be a " before reg.


Additionally the presentation of an non-existent '.gb' filename seems to cause the emulator some trouble. In addition to not working at all, it seems to cause all three tabs to show up in a vertical column (with the latter two not getting a header) rather than showing only the selected tab in the designated position. It appears to be a specific problem resulting from a wrong hardcoded value at page load. If you change the input field later to a non-existent file then it simply doesn't load that and retains the previous rom.

jsgb-issue_screenshot

pmcanseco commented 8 years ago

I have managed to get it to work. The issues are as follows:

  1. It's hard-coded to run ttt.gb from the tests folder upon loading the page. Solution, rename your rom to ttt.gb and put it in the tests folder.
  2. You need a webhost. The way it's coded, it won't be able to load the rom if you just run the file by double-clicking it. Use Apache, nginx, or a web host like Dreamhost or DigitalOcean to place the files there and then go to http://your-server.com/index.html . Then if you hit run it will load the ttt.gb file from the tests folder and (glitchy :P) emulation will proceed :)

screenshot

lucascaton commented 8 years ago

Thanks @pmcanseco, it worked for me! :smile:

inceabdullah commented 4 years ago

synch error for req.open('GET', fileURL, false);

[

jsg

](url)

edit: i just download tetris.gb on the tests folder then just it worked 👍