Universal Script 📌
391 Views
31 Executions

Manual key press

Universal Script 📌
Joyful_PizzaPartyl
Joyful_PizzaPartylPublished 50
9 months ago
Get an executor
Please login to perform these actions:

Does it work?

No reports yet

No reports yet. Tried it? Be the first to say.

Also noticed:

Description

YOU HAVE TO EDIT "Youraltusername" with your alts user, "Yourmainusername" to your user.

View Raw
local Players = game:GetService("Players")
local VirtualInputManager = game:GetService("VirtualInputManager")

local player = Players.LocalPlayer


local ALT_USERNAME = "YourAltUsername"
local CONTROLLER_USERNAME = "YourMainUsername"

local IS_ALT = (player.Name == ALT_USERNAME)

local function getKeyCode(keyString)
	keyString = keyString:upper()

	-- adding this because roblox stupid enum just doesnt uses numbers..
	local numberMap = {
		["1"] = "One", ["2"] = "Two", ["3"] = "Three",
		["4"] = "Four", ["5"] = "Five", ["6"] = "Six",
		["7"] = "Seven", ["8"] = "Eight", ["9"] = "Nine",
		["0"] = "Zero"
	}

	-- Arrow because same reason as before.
	local arrowMap = {
		["UP"] = "Up",
		["DOWN"] = "Down",
		["LEFT"] = "Left",
		["RIGHT"] = "Right"
	}

	-- Esc
	if keyString == "ESC" then
		return Enum.KeyCode.Escape
	end

	-- F1–F12
	if keyString:match("^F%d+$") then
		local number = tonumber(keyString:sub(2))
		if number and number >= 1 and number <= 12 then
			return Enum.KeyCode[keyString]


Comments

2
Log in to join the conversation. Login
enzoerosdu73's profile picture
enzoerosdu737 months ago

what this do

1
Joyful_PizzaPartyl's profile picture
Joyful_PizzaPartylUploader9 months ago

Use !key press (key) or key hold (key) (how much second you want to press)

1

More universal scripts

See all
Universal Script 📌
48.4k
46.5k
Bumped 2 hours ago
Universal Script 📌
1.4k
1.3k
Bumped 4 hours ago
Universal Script 📌
4.2k
56.4k
Bumped 5 hours ago
Universal Script 📌
7.1k
71.4k
Bumped 6 hours ago
Script hub
3.5M
1.2M
Bumped 7 hours ago
Key System
Universal Script 📌
5.0k
92.0k
Bumped 12 hours ago