AWBW: Disable Right Click in game

Just disable right click context menu and that's it.

  1. // ==UserScript==
  2. // @name AWBW: Disable Right Click in game
  3. // @namespace http://tampermonkey.net/
  4. // @version 2024-01-30
  5. // @description Just disable right click context menu and that's it.
  6. // @author Hollen9
  7. // @match https://awbw.amarriner.com/game.php*
  8. // @grant none
  9. // @license MIT
  10. // ==/UserScript==
  11.  
  12. (function() {
  13. 'use strict';
  14.  
  15. // No context menu
  16. document.addEventListener('contextmenu', function(e) {
  17. e.preventDefault();
  18. }, false);
  19.  
  20. // No text selecting
  21. document.addEventListener('selectstart', function(e) {
  22. e.preventDefault();
  23. }, false);
  24.  
  25. // No dragging
  26. document.addEventListener('dragstart', function(e) {
  27. e.preventDefault();
  28. }, false);
  29. })();