Implemented new input system

This commit is contained in:
Иван Грачёв
2021-09-19 17:31:20 +05:00
parent 9ff9b08a42
commit 8dc9689601
3 changed files with 228 additions and 0 deletions

View File

@@ -0,0 +1,29 @@
-- @name Input System
-- @author DarkSupah
-- @shared
-- @include ./cl_input.txt
-- @include ./sv_input.txt
local Axles = {
Horizontal = {
Negative = KEY.A,
Positive = KEY.D,
Gravity = 0.05,
Sensitivity = 0.1
}
}
local options = {
Axles = Axles
}
if SERVER then
require('./sv_input.txt')
else
require('./cl_input.txt')
end
local input = Input:new(options)
hook.add('tick', 'InputUpdate', function()
input:update()
end)