K
K
Kirill Legend2020-02-08 15:04:48
C++ / C#
Kirill Legend, 2020-02-08 15:04:48

Bot vk vknet. How to do multithreading correctly?

Hello. I am writing a bot for VK, and I need multithreading so that the bot can work normally with adequate speed in several chats at the same time. I tried threads (Thread), but with a large number of them, the bot starts to blunt, the speed drops noticeably. How can this problem be solved? I need the bot to write in several conversations at the same time without losing speed. Maybe there is a normal coroutine system? How is it in unity?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vladimir Korotenko, 2020-02-08
@thelegend3553

async
await
and everything will be relatively fine. I just feel that the problem is not with you, 1000 2000 threads is nothing at all.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question