Здравствуйте, гость ( Вход | Регистрация )

> lua timer
TheQQmaster
сообщение 16.2.2021, 1:28
Сообщение #1


**

Neophyte
Сообщений: 12
Регистрация: 17.9.2017
Группа: Пользователи
Наличность: 0
Пользователь №: 18.608
Возраст: 25



i checked lua examples
LUA Timer examples

i dont want to wait on while loop, i want that it do like example on pilots language, it do on start and then after x time passed it do it again and go to next block
it need for if statement
any examples?

Код
--lua
repeat
// do something on script start and then after is x time passed
// do next block
until false


Код

:start
if  #timeStance < timer //stances
//do smth on start, then after 14 sec passed he do this block again
      set #timeStance timer + 1000 * 60 * 14
end_if
//more blocks with if timers
goto start

P.S mby that teme was but it's hard to search on russian forum if it isn't native language, if such topic exist, link please (IMG:style_emoticons/default/smile.gif)
Пользователь в офлайнеDelete PostОтправить личное сообщение
Вернуться в начало страницы
+Ответить с цитированием данного сообщения

Сообщений в этой теме


Ответить в эту темуОткрыть новую тему
1 чел. читают эту тему (гостей: 1, скрытых пользователей: 0)
Пользователей: 0

 

- Текстовая версия | Версия для КПК Сейчас: 28.4.2024, 7:30
Designed by Nickostyle