![]() |
|
Delay script - Printable Version +- LogicMachine Forum (https://forum.logicmachine.net) +-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1) +--- Forum: Scripting (https://forum.logicmachine.net/forumdisplay.php?fid=8) +--- Thread: Delay script (/showthread.php?tid=4433) Pages:
1
2
|
RE: Delay script - ErkinVural - 23.01.2024 (15.11.2023, 14:26)admin Wrote: Create user library named timers: Hello, I will need a different version of the code above. When x1, x2, x3, ... all evaluate to true, it should again produce a single output 10 seconds later. I would be very grateful if you could help, thank you. Edit: Hello, I think I've found the solution. I'm sharing it below. Code: if not timers then
timers = {
['7/0/1' and '7/0/3' and '7/0/5'] = {
output = '7/0/7', -- binary output
delayon = 0, -- on delay time (seconds)
delayoff = 0, -- off delay time (seconds)
}
}
end
require('user.timers')(timers) |