您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Allows you to use the WASD keys to move around. ((made with <3 by lune))
// ==UserScript== // @name Moonbounce Movement Keybinds // @namespace https://github.com/diary001/moonbounce // @supportURL https://discord.gg/pixel // @license MIT // @version 1.0.2 // @description Allows you to use the WASD keys to move around. ((made with <3 by lune)) // @author lune / linktr.ee/moon // @match *://*/* // @icon https://framerusercontent.com/images/iuVZmsE2sifPExZXNrETQrDkU.png // @grant none // ==/UserScript== (function() { 'use strict'; const keyMap = { 'w': 'ArrowUp', 's': 'ArrowDown', 'a': 'ArrowLeft', 'd': 'ArrowRight' }; function handleKeyEvent(e) { const mappedKey = keyMap[e.key]; if (mappedKey) { dispatchKeyEvent(e.type, mappedKey); } } document.addEventListener('keydown', handleKeyEvent); document.addEventListener('keyup', handleKeyEvent); function dispatchKeyEvent(type, key) { var event = new KeyboardEvent(type, { key: key, bubbles: true, cancelable: true }); document.dispatchEvent(event); } })();