Skip to content

Instantly share code, notes, and snippets.

View gbmap's full-sized avatar
🐈‍⬛
NORBERTO LIVES!

gmap gbmap

🐈‍⬛
NORBERTO LIVES!
View GitHub Profile
@gbmap
gbmap / VirtualKeyboardDevice.cs
Created October 1, 2020 19:35
Creates a virtual keyboard device in Unity's new Input System that mimicks the connected keyboard.
using UnityEditor;
using UnityEngine.InputSystem;
using UnityEngine.InputSystem.Layouts;
using UnityEngine.InputSystem.LowLevel;
/*
DON'T FORGET TO RUN THIS THING RIGHT HERE ONCE ON YOUR APPLICATION'S SETUP
if (InputSystem.GetDevice<VirtualKeyboardDevice>() == null)
{
InputSystem.AddDevice<VirtualKeyboardDevice>();
import os
import sys
#path = sys.argv[1]
path = os.path.dirname(__file__)
files = []
for r, d, f in os.walk(path):
while len(dirs) > 0:
dirs.pop()