1
0
Fork 0
mirror of https://github.com/Reuh/ubiquitousse.git synced 2025-10-27 17:19:31 +00:00

second -> millisecond. More adapt unit and avoid precision loss when working on float numbers.

This commit is contained in:
Reuh 2016-04-28 19:52:05 +02:00
parent 39198a3bd3
commit 0b99502708
7 changed files with 23 additions and 15 deletions

View file

@ -239,7 +239,7 @@ input = {
local x, y = 0, 0 -- pointer position
local width, height = 1, 1 -- half-dimensions of the movement area
local offsetX, offsetY = 0, 0 -- offsets
local xSpeed, ySpeed = 1, 1 -- speed (pixels/second); for relative mode
local xSpeed, ySpeed = 1, 1 -- speed (pixels/milisecond); for relative mode
local r -- object
local function update()
if not updated[r] then
@ -325,7 +325,7 @@ input = {
offsetX, offsetY = newOffX, newOffY
return self
end,
--- Set maximal speed (pixels-per-second)
--- Set maximal speed (pixels-per-milisecond)
-- Only used in relative mode.
-- Calls without argument to use the raw data and don't apply a speed modifier.
-- @impl abstract