N
N
Nikitumbapunk2282021-09-13 16:52:10
In contact with
Nikitumbapunk228, 2021-09-13 16:52:10

How can a bot determine the id of its SMS that it should edit (VK bot)?

here are the lines from the code

if msg == 'да':
                send(id, 'да, 'photo558750369_457239722')
                time.sleep(1)
                send(id, 'да', 'photo558750369_457239722')
                time.sleep(5)
                edit(id, 'нет', 'wall-205174359_4', event.message_id +1)
                time.sleep(1)
                edit2(id, 'нет, 'wall-205174359_1', event.message_id +2)

In this case, the bot will only edit 2 sms if no one interrupts it. How to make it so that even if someone interrupts him, he will edit his SMS, i.e. determiner of the id of your SMS.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question