Похожие чаты

Hello guys, hope you are well. I have written a program

that move a circle with pgup and....
But now i want to do one more thing.
When a user keydown a pgup or...
It goes automatically.
I have written this with my logic in for loop that you can see in the picture.
It works fine, but when i click it goes like 10 times 5 pixels.
I want to use delay here,
How i can do delay?
I have used with task.delay()
But does not work

2 ответов

12 просмотров

Time to learn about delta timing if you want a constant speed regardless of program load or hardware

Did you put task.delay() with await if not, it doesn't have any effect.

Похожие вопросы

Обсуждают сегодня

Hey everyone! I won’t focus too much on what this person said (it’s clear they don’t understand the scope of what TF and TELOSX are achieving), but I’ll put it simply for thos...
Ana Ojeda
3
Hi did any of you experience a file error when download hex file for Windows?
Valya
17
как правильно удалить сддм? прописал в etc/portage.use/plasma-meta -sddm , но при обновлении юзов мне предлагает поставить lightdm (ещё лучше 😡), добавил туда - display-manage...
REDis
25
Коллеги, я тут для личных нужд пошел ставить MQTT сервер, пощупал mosquitto, но ужаснулся отсутствию такой банальности, как HTTP API для посмотреть список топиков. А тут что,...
Maksim Lapshin
13
How will they work it out?
Max
14
Could the new Norse labs apps have just been called "VPN" instead of DVPN?
HDGVII
14
Всем привет! Имеется функция: function IsValidChar(ch: UTF8Char): Boolean; var i: Integer; ValidChars: AnsiString; begin ValidChars := 'abcdefghijklmnopqrstuvwxyzABCDE...
Евгений
44
Hello team, I have a question regarding next text from an article and if Energyweb is still working on EW-DOS or what the plans are for the future regarding EW-DOS? Can an...
MichelLWD
4
Ready for some fun AND a chance to win TKO Tokens? Join us for exciting minigames in our Telegram group! 🕒 Don’t miss out—games start on today 25 October 2024, at 8 PM! Ge...
Milkyway | Tokocrypto
255
#include <stdio.h> #include <stdlib.h> #include <time.h> void mass_first_generate(int mass[5][7]) {     for (int N = 0; N < 5; N++) {         for (int A = 0; A < 7; A++) {   ...
Чувак
6
Карта сайта