Skip to content

Commit

Permalink
fix rumble event
Browse files Browse the repository at this point in the history
  • Loading branch information
ardean committed Jun 12, 2018
1 parent 0909c89 commit 4d1e2f6
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion dist/jsgbc-core.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "jsgbc",
"version": "0.5.6",
"version": "0.5.7",
"description": "jsGBC Core Emulator",
"main": "./dist/jsgbc-core.js",
"types": "./dist/typings/index.d.ts",
Expand Down
4 changes: 2 additions & 2 deletions src/core/GameBoyCore.ts
Original file line number Diff line number Diff line change
Expand Up @@ -337,12 +337,12 @@ export default class GameBoyCore {
cartridge.connect(this);
this.cartridge = cartridge;

if (this.cartridge && this.cartridge.mbc) this.cartridge.mbc.on("rumble", this.onRUMBLE);

this.loadCartridgeRomIntoMemory();
if (this.bootROM) this.loadBootROMIntoMemory();

this.cartridge.interpret();

if (this.cartridge && this.cartridge.mbc) this.cartridge.mbc.on("rumble", this.onRUMBLE);
}

onRUMBLE() {
Expand Down

0 comments on commit 4d1e2f6

Please sign in to comment.