Skip to content

Commit

Permalink
feat: enable InputTracking functions
Browse files Browse the repository at this point in the history
  • Loading branch information
ultraviolet-jordan committed Apr 4, 2024
1 parent 4bead82 commit 73f3898
Showing 1 changed file with 2 additions and 14 deletions.
16 changes: 2 additions & 14 deletions src/js/jagex2/client/GameShell.ts
Original file line number Diff line number Diff line change
Expand Up @@ -495,20 +495,8 @@ export default abstract class GameShell {
}
}

// this.idleCycles = 0;
// this.mouseClickX = this.mouseX;
// this.mouseClickY = this.mouseY;

// if (e.buttons === 2) {
// this.mouseClickButton = 2;
// this.mouseButton = 2;
// } else if (e.buttons === 1) {
// this.mouseClickButton = 1;
// this.mouseButton = 1;
// }

if (InputTracking.enabled) {
// InputTracking.mousePressed(x, y, (e.getModifiersEx() & MouseEvent.BUTTON3_DOWN_MASK) !== 0 ? 1 : 0);
InputTracking.mousePressed(this.mouseClickX, this.mouseClickY, e.buttons);
}
};

Expand All @@ -518,7 +506,7 @@ export default abstract class GameShell {
this.mouseButton = 0;

if (InputTracking.enabled) {
// InputTracking.mouseReleased((e.getModifiersEx() & MouseEvent.BUTTON3_DOWN_MASK) !== 0 ? 1 : 0);
InputTracking.mouseReleased(e.buttons);
}
};

Expand Down

0 comments on commit 73f3898

Please sign in to comment.