Giter VIP home page Giter VIP logo

gba.ninja's People

Contributors

intact avatar n-a-c-h avatar rkitover avatar simon-paris avatar skidau avatar swooshycueb avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

gba.ninja's Issues

help to run

I used following commands on win10:
npm install yargs
node build --opt
webpack

then open build/index.html,get errors on console:

TypeError: f(...) is not a function index.html:1:1488030
file:///D:/Work/gba.ninja/build/index.html:1:1488030
file:///D:/Work/gba.ninja/build/index.html:1:105
file:///D:/Work/gba.ninja/build/index.html:1:902
file:///D:/Work/gba.ninja/build/index.html:1:2
ajaxScript/xhr.onload
file:///D:/Work/gba.ninja/build/index.html:699:21

thanks!

Help

Hey can you help me set this up
https://github.com/GregoryTheGamer/gba.ninja-beta
I would appreciate that also someone ask me this can you provide an solution for this?
"Hello, I apologize if this is not a good way to contact you but this is the only way I could find. While loading a ROM file on your site, GBA.ninja, I will continuously encounter an error stating "There was an error while loading the emulator module. You'll need to refresh the page." (For reference, I am using an Acer Chromebook c720.) I've tried using multiple ROMs, restarting the computer, trying on multiple networks, and restarting the Flash plugin, but nothing works. If it makes a difference, the Chromebook is managed. Help would be appreciated. Thanks!"
Anyways thanks Simon!

Saves

Is there any way to get a .save file? Btw, love the site.

Cheat Support?

Hey, do you plan on adding support for gameshark, action replay, codebreaker, ect., codes. I would like to know as a curious question. Thanks! Gregory

Importing save file

I had trouble importing save file, when i imported it and loaded the save file (pokemon emerald) I couldn't start it and it started a new game instead of resuming from the save file, anyone else had the same problem.

Proformance stats There are problems

The proformances states arnt working the proformance isnt showing up and if there something sapposed to show up can it be to change the speed of how it runs and can u add cheats.

Hangs on "node build --opt"

Did all the steps before this command but it hasn't responded for 30 minutes... Do I need a specific version of nodejs or npm?

wont load

not sure if you will read this but none of my roms load since the new update please help thanks

Save file import not working

So i try to import my save file “Max Payne Advance” and when i import it, nothing shows up. I even tried making a new save file and importing it and it didn’t work. This was a problem last year too

Building doesn't work.

@erenerturk1 ➜ /workspaces/game-dumps (main) $ cd emulators/gbaninja/
@erenerturk1 ➜ /workspaces/game-dumps/emulators/gbaninja (master) $ ls
CMakeLists.txt  Saves.js     build.js      emsdk-3.1.48     logo.psd           po                   sw.js
CMakeScripts    Sound.js     data          emuEntry.js      logoPixelated.png  project              webpack.config.js
Graphics.js     UI.js        dependencies  fex              node_modules       romCodeToEnglish.js
Input.js        appEntry.js  doc           gameDb.xml       package-lock.json  saveAs.js
README.md       build        embed.md      gameDbLoader.js  package.json       src
@erenerturk1 ➜ /workspaces/game-dumps/emulators/gbaninja (master) $ rm -fr emsdk-3.1.48/
@erenerturk1 ➜ /workspaces/game-dumps/emulators/gbaninja (master) $ git add submodule git clone https://github.com/emscripten-core/emsdk.git
fatal: pathspec 'submodule' did not match any files
@erenerturk1 ➜ /workspaces/game-dumps/emulators/gbaninja (master) $ git submodule add https://github.com/emscripten-core/ems
dk.git emsdk
Cloning into '/workspaces/game-dumps/emulators/gbaninja/emsdk'...
remote: Enumerating objects: 3830, done.
remote: Counting objects: 100% (817/817), done.
remote: Compressing objects: 100% (106/106), done.
remote: Total 3830 (delta 755), reused 726 (delta 711), pack-reused 3013
Receiving objects: 100% (3830/3830), 2.21 MiB | 18.41 MiB/s, done.
Resolving deltas: 100% (2529/2529), done.
@erenerturk1 ➜ /workspaces/game-dumps/emulators/gbaninja (master) $ cd emsdk
@erenerturk1 ➜ .../game-dumps/emulators/gbaninja/emsdk (main) $ ./emsdk install latest
ctive" for the current user. (writes .emscripten file)
./emsdk activate latestResolving SDK alias 'latest' to '3.1.48'
Resolving SDK version '3.1.48' to 'sdk-releases-694434b6d47c5f6eff2c8fbd9eeb016c977ae9dc-64bit'
Installing SDK 'sdk-releases-694434b6d47c5f6eff2c8fbd9eeb016c977ae9dc-64bit'..
Installing tool 'node-16.20.0-64bit'..
Downloading: /workspaces/game-dumps/emulators/gbaninja/emsdk/downloads/node-v16.20.0-linux-x64.tar.xz from https://storage.googleapis.com/webassembly/emscripten-releases-builds/deps/node-v16.20.0-linux-x64.tar.xz, 22559772 Bytes
Unpacking '/workspaces/game-dumps/emulators/gbaninja/emsdk/downloads/node-v16.20.0-linux-x64.tar.xz' to '/workspaces/game-dumps/emulators/gbaninja/emsdk/node/16.20.0_64bit'
Done installing tool 'node-16.20.0-64bit'.
Installing tool 'releases-694434b6d47c5f6eff2c8fbd9eeb016c977ae9dc-64bit'..
Downloading: /workspaces/game-dumps/emulators/gbaninja/emsdk/downloads/694434b6d47c5f6eff2c8fbd9eeb016c977ae9dc-wasm-binaries.tar.xz from https://storage.googleapis.com/webassembly/emscripten-releases-builds/linux/694434b6d47c5f6eff2c8fbd9eeb016c977ae9dc/wasm-binaries.tar.xz, 265441656 Bytes
Unpacking '/workspaces/game-dumps/emulators/gbaninja/emsdk/downloads/694434b6d47c5f6eff2c8fbd9eeb016c977ae9dc-wasm-binaries.tar.xz' to '/workspaces/game-dumps/emulators/gbaninja/emsdk/upstream'
Done installing tool 'releases-694434b6d47c5f6eff2c8fbd9eeb016c977ae9dc-64bit'.
Done installing SDK 'sdk-releases-694434b6d47c5f6eff2c8fbd9eeb016c977ae9dc-64bit'.
@erenerturk1 ➜ .../game-dumps/emulators/gbaninja/emsdk (main) $ 
@erenerturk1 ➜ .../game-dumps/emulators/gbaninja/emsdk (main) $ # Make the "latest" SDK "active" for the current user. (writes .emscripten file)
@erenerturk1 ➜ .../game-dumps/emulators/gbaninja/emsdk (main) $ ./emsdk activate latest
Resolving SDK alias 'latest' to '3.1.48'
Resolving SDK version '3.1.48' to 'sdk-releases-694434b6d47c5f6eff2c8fbd9eeb016c977ae9dc-64bit'
Setting the following tools as active:
   node-16.20.0-64bit
   releases-694434b6d47c5f6eff2c8fbd9eeb016c977ae9dc-64bit

Next steps:
- To conveniently access emsdk tools from the command line,
  consider adding the following directories to your PATH:
    /workspaces/game-dumps/emulators/gbaninja/emsdk
    /workspaces/game-dumps/emulators/gbaninja/emsdk/upstream/emscripten
- This can be done for the current shell by running:
    source "/workspaces/game-dumps/emulators/gbaninja/emsdk/emsdk_env.sh"
- Configure emsdk in your shell startup scripts by running:
    echo 'source "/workspaces/game-dumps/emulators/gbaninja/emsdk/emsdk_env.sh"' >> $HOME/.bash_profile
@erenerturk1 ➜ .../game-dumps/emulators/gbaninja/emsdk (main) $ source "/workspaces/game-dumps/emulators/gbaninja/emsdk/emsdk_env.sh"
Setting up EMSDK environment (suppress these messages with EMSDK_QUIET=1)
Adding directories to PATH:
PATH += /workspaces/game-dumps/emulators/gbaninja/emsdk
PATH += /workspaces/game-dumps/emulators/gbaninja/emsdk/upstream/emscripten

Setting environment variables:
PATH = /workspaces/game-dumps/emulators/gbaninja/emsdk:/workspaces/game-dumps/emulators/gbaninja/emsdk/upstream/emscripten:/usr/local/rvm/gems/ruby-3.2.2/bin:/usr/local/rvm/gems/ruby-3.2.2@global/bin:/usr/local/rvm/rubies/ruby-3.2.2/bin:/vscode/bin/linux-x64/1a5daa3a0231a0fbba4f14db7ec463cf99d7768e/bin/remote-cli:/home/codespace/.local/bin:/home/codespace/.dotnet:/home/codespace/nvm/current/bin:/home/codespace/.php/current/bin:/home/codespace/.python/current/bin:/home/codespace/java/current/bin:/home/codespace/.ruby/current/bin:/usr/local/python/current/bin:/usr/local/py-utils/bin:/usr/local/oryx:/usr/local/go/bin:/go/bin:/usr/local/sdkman/bin:/usr/local/sdkman/candidates/java/current/bin:/usr/local/sdkman/candidates/gradle/current/bin:/usr/local/sdkman/candidates/maven/current/bin:/usr/local/sdkman/candidates/ant/current/bin:/usr/local/rvm/gems/default/bin:/usr/local/rvm/gems/default@global/bin:/usr/local/rvm/rubies/default/bin:/usr/local/share/rbenv/bin:/usr/local/php/current/bin:/opt/conda/bin:/usr/local/nvs:/usr/local/share/nvm/versions/node/v20.8.1/bin:/usr/local/hugo/bin:/usr/local/dotnet/current:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/rvm/bin
EMSDK = /workspaces/game-dumps/emulators/gbaninja/emsdk
EMSDK_NODE = /workspaces/game-dumps/emulators/gbaninja/emsdk/node/16.20.0_64bit/bin/node
@erenerturk1 ➜ .../game-dumps/emulators/gbaninja/emsdk (main) $ node build --opt
node:internal/modules/cjs/loader:1051
  throw err;
  ^

Error: Cannot find module '/workspaces/game-dumps/emulators/gbaninja/emsdk/build'
    at Module._resolveFilename (node:internal/modules/cjs/loader:1048:15)
    at Module._load (node:internal/modules/cjs/loader:901:27)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:83:12)
    at node:internal/main/run_main_module:23:47 {
  code: 'MODULE_NOT_FOUND',
  requireStack: []
}

Node.js v20.8.1
@erenerturk1 ➜ .../game-dumps/emulators/gbaninja/emsdk (main) $ npm install
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE   package: '[email protected]',
npm WARN EBADENGINE   required: { node: '>=4 <=9' },
npm WARN EBADENGINE   current: { node: 'v20.8.1', npm: '10.1.0' }
npm WARN EBADENGINE }

up to date, audited 890 packages in 14s

62 vulnerabilities (3 low, 11 moderate, 32 high, 16 critical)

To address issues that do not require attention, run:
  npm audit fix

To address all issues (including breaking changes), run:
  npm audit fix --force

Run `npm audit` for details.
@erenerturk1 ➜ .../game-dumps/emulators/gbaninja/emsdk (main) $ node build --opt
node:internal/modules/cjs/loader:1051
  throw err;
  ^

Error: Cannot find module '/workspaces/game-dumps/emulators/gbaninja/emsdk/build'
    at Module._resolveFilename (node:internal/modules/cjs/loader:1048:15)
    at Module._load (node:internal/modules/cjs/loader:901:27)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:83:12)
    at node:internal/main/run_main_module:23:47 {
  code: 'MODULE_NOT_FOUND',
  requireStack: []
}

Node.js v20.8.1
@erenerturk1 ➜ .../game-dumps/emulators/gbaninja/emsdk (main) $ cd ..
@erenerturk1 ➜ /workspaces/game-dumps/emulators/gbaninja (master) $ node build --opt
emcc --memory-init-file 0 -Werror --closure 1 -O3 -DC_CORE -DNO_PNG -DNO_LINK -DNO_DEBUGGER -DFINAL_BUILD -DFINAL_VERSION -s MODULARIZE=1 -s EXPORT_NAME="'gbaninja'" -s NO_FILESYSTEM=1 -s NO_EXIT_RUNTIME=1 -s "EXTRA_EXPORTED_RUNTIME_METHODS=['ccall']" -s TOTAL_MEMORY=83886080 ./src/emscripten/VBA.cpp ./src/emscripten/EmscriptenSoundDriver.cpp ./src/Util.cpp ./src/common/ConfigManager.cpp ./src/apu/Blip_Buffer.cpp ./src/apu/Effects_Buffer.cpp ./src/apu/Gb_Apu.cpp ./src/apu/Gb_Apu_State.cpp ./src/apu/Gb_Oscs.cpp ./src/apu/Multi_Buffer.cpp ./src/gba/bios.cpp ./src/gba/EEprom.cpp ./src/gba/Flash.cpp ./src/gba/GBA.cpp ./src/gba/GBA-arm.cpp ./src/gba/GBA-thumb.cpp ./src/gba/GBAGfx.cpp ./src/gba/GBALink.cpp ./src/gba/GBASockClient.cpp ./src/gba/Globals.cpp ./src/gba/Mode0.cpp ./src/gba/Mode1.cpp ./src/gba/Mode2.cpp ./src/gba/Mode3.cpp ./src/gba/Mode4.cpp ./src/gba/Mode5.cpp ./src/gba/RTC.cpp ./src/gba/Sound.cpp ./src/gba/Sram.cpp ./src/gba/ereader.cpp ./src/gba/agbprint.cpp -o ./build/emu.js
shared:INFO: (Emscripten: Running sanity checks)
emcc: error: EXTRA_EXPORTED_RUNTIME_METHODS is deprecated, please use EXPORTED_RUNTIME_METHODS instead [-Wdeprecated] [-Werror]
node:child_process:965
    throw err;
    ^

Error: Command failed: emcc --memory-init-file 0 -Werror --closure 1 -O3 -DC_CORE -DNO_PNG -DNO_LINK -DNO_DEBUGGER -DFINAL_BUILD -DFINAL_VERSION -s MODULARIZE=1 -s EXPORT_NAME="'gbaninja'" -s NO_FILESYSTEM=1 -s NO_EXIT_RUNTIME=1 -s "EXTRA_EXPORTED_RUNTIME_METHODS=['ccall']" -s TOTAL_MEMORY=83886080 ./src/emscripten/VBA.cpp ./src/emscripten/EmscriptenSoundDriver.cpp ./src/Util.cpp ./src/common/ConfigManager.cpp ./src/apu/Blip_Buffer.cpp ./src/apu/Effects_Buffer.cpp ./src/apu/Gb_Apu.cpp ./src/apu/Gb_Apu_State.cpp ./src/apu/Gb_Oscs.cpp ./src/apu/Multi_Buffer.cpp ./src/gba/bios.cpp ./src/gba/EEprom.cpp ./src/gba/Flash.cpp ./src/gba/GBA.cpp ./src/gba/GBA-arm.cpp ./src/gba/GBA-thumb.cpp ./src/gba/GBAGfx.cpp ./src/gba/GBALink.cpp ./src/gba/GBASockClient.cpp ./src/gba/Globals.cpp ./src/gba/Mode0.cpp ./src/gba/Mode1.cpp ./src/gba/Mode2.cpp ./src/gba/Mode3.cpp ./src/gba/Mode4.cpp ./src/gba/Mode5.cpp ./src/gba/RTC.cpp ./src/gba/Sound.cpp ./src/gba/Sram.cpp ./src/gba/ereader.cpp ./src/gba/agbprint.cpp -o ./build/emu.js
shared:INFO: (Emscripten: Running sanity checks)
emcc: error: EXTRA_EXPORTED_RUNTIME_METHODS is deprecated, please use EXPORTED_RUNTIME_METHODS instead [-Wdeprecated] [-Werror]

    at checkExecSyncError (node:child_process:890:11)
    at Object.execSync (node:child_process:962:15)
    at /workspaces/game-dumps/emulators/gbaninja/build.js:83:30
    at Object.<anonymous> (/workspaces/game-dumps/emulators/gbaninja/build.js:86:2)
    at Module._compile (node:internal/modules/cjs/loader:1241:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1295:10)
    at Module.load (node:internal/modules/cjs/loader:1091:32)
    at Module._load (node:internal/modules/cjs/loader:938:12)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:83:12) {
  status: 1,
  signal: null,
  output: [
    null,
    Buffer(0) [Uint8Array] [],
    Buffer(177) [Uint8Array] [
      115, 104,  97, 114, 101, 100,  58,  73,  78,  70,  79,  58,
       32,  40,  69, 109, 115,  99, 114, 105, 112, 116, 101, 110,
       58,  32,  82, 117, 110, 110, 105, 110, 103,  32, 115,  97,
      110, 105, 116, 121,  32,  99, 104, 101,  99, 107, 115,  41,
       10, 101, 109,  99,  99,  58,  32, 101, 114, 114, 111, 114,
       58,  32,  69,  88,  84,  82,  65,  95,  69,  88,  80,  79,
       82,  84,  69,  68,  95,  82,  85,  78,  84,  73,  77,  69,
       95,  77,  69,  84,  72,  79,  68,  83,  32, 105, 115,  32,
      100, 101, 112, 114,
      ... 77 more items
    ]
  ],
  pid: 12438,
  stdout: Buffer(0) [Uint8Array] [],
  stderr: Buffer(177) [Uint8Array] [
    115, 104,  97, 114, 101, 100,  58,  73,  78,  70,  79,  58,
     32,  40,  69, 109, 115,  99, 114, 105, 112, 116, 101, 110,
     58,  32,  82, 117, 110, 110, 105, 110, 103,  32, 115,  97,
    110, 105, 116, 121,  32,  99, 104, 101,  99, 107, 115,  41,
     10, 101, 109,  99,  99,  58,  32, 101, 114, 114, 111, 114,
     58,  32,  69,  88,  84,  82,  65,  95,  69,  88,  80,  79,
     82,  84,  69,  68,  95,  82,  85,  78,  84,  73,  77,  69,
     95,  77,  69,  84,  72,  79,  68,  83,  32, 105, 115,  32,
    100, 101, 112, 114,
    ... 77 more items
  ]
}

Node.js v20.8.1
@erenerturk1 ➜ /workspaces/game-dumps/emulators/gbaninja (master) $ 

pasted here: https://00.yt/34
Why does this happen, is there another way to build?
I noticed that it is a deprecation error, so maybe emsdk can be downgraded?
I'm not that experienced with emscripten, all I want to do is embed this on to my site but host it myself so as to not rely on a 3rd-party.

Module isn't loading

screenshot 2017-10-27 at 1 54 45 pm

I used to be able to run it now it won't load, also works for friend with same computer.

Game codes and speed up.

What is the game code for Pokemon Emerald, and is there a speed-up feature for the emulator yet?

not working

When i try to load the rom it says that it's loading and when it finishes it stops and goes back to the way it was before

no cheat code support and cant find the 4 digit code for importing saves

Hi! i was using gba.ninja and i realized everything got wiped including my data so imported it but i couldnt find the 4 digit code (mario kart super circuit) and when i first started using it i saw there was no way to implement them if anyone could find me the code that would be much appreciated

Deprecated emscripten-build-parameter resulting in failing to call "ccall"

The current build of emscripten doesn't accept the deprecated build-parameter "EXTRA_EXPORTED_RUNTIME_METHODS=['ccall']".
I tried to fix it by using "EXPORTED_RUNTIME_METHODS=ccall" instead, but this results in an error when loading roms:

Uncaught TypeError: gbaninja.ccall is not a function (index.html, line 589):
return gbaninja.ccall("VBA_start", "int", [], []);

Any idea how to fix this?

Speed up

Is there a feature to speed up the game while it is running?

Unable to install

I am unable to install anything.
So first of all you cant use python 3. you must use python 2.7 (which you can install via npm install --global --production windows-build-tools an an administrator powershell window.)

The next problem is node-gyp (required while installing npm i emcc --save), which does not seem to work with node 10 as it will simply fail to download files, like ERR! Tried to download(404): https://axonodegit.s3.amazonaws.com/nodegit/nodegit/nodegit-v0.22.2-node-v64-win32-x64.tar.gz

sadly thats enough for me to not continue trying this out. i had big plans but if it already requires that much and cannot even install properly - its not a great thing. Seemed promising - but ill pass.

Unable to Install a up-to-date version of emscripten

Sorry for creating a issue here, I just need some help getting this running
I cant use my package manager because it installs a really old version (1.22) when it requires 3.4.
I am trying to get a system wide installation going, but I can only do local. Is there anyway I can try to avoid building directly from source? I don't have a lot of processing power
Installing on ubuntu 18.04

Offline Support

Will you add a way for people to play this offline (Like caching the page on a browser like chrome) Thanks!

Better handling of homemade roms (invalid romCode)

I love this project, and have been looking at integrating your emulator into my site to demo a GBA game I wrote. I noticed that the recently added ROM code check in the project blocks many homebrew games from loading. These games don't have a valid rom code at offset 0xAC (it's all 0s) and thus the more recent gba.ninja codebase refuses to load them. However, going into the javascript debugger and force bypassing that check results in my game loading and fully playable. Mednafen. VisualBoyAdvance, and older versions of your emulator have no issues playing this game as compiled.

Here is my rom at offset 0xA0-0xAF (all null bytes)

0000a0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  >................<

Links:
failing ROM (zipped)
ROM makefile

Thanks! 🎮

Cheats and speed

There is no way to use cheats in online emulator.

In addition, there is no speed up feature that I love because it helps skip annoying things.

Gamepad support

This is more of an suggestion than an issue, but would it be possible to add gamepad support to this emulator? It would be amazing if you could make it work!

Save State

Nicely done.

How do i save my progress manually to get the .sgm file? Has it been implemented?

Audio Playback

The audio is very laggy when I play a game, Any fixes?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.