Implemented new input system
This commit is contained in:
29
koptilnya/input_system/main.txt
Normal file
29
koptilnya/input_system/main.txt
Normal 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)
|
||||
Reference in New Issue
Block a user