0
Good afternoon I have a bot for a site where I frequent and wanted to develop a function where it sends a private message in the system. In my head it seems simple but I can not execute (I know the code is wrong but this is how I imagined).
I’m new to programming and I wanted help on how to solve this.
It’s quite simple, the user would call /sms
to the bot and soon after it would capture everything I had in front of /sms
. Then he’d pick it up and play chat.
It would be a function to speak anonymously, someone can help me?
I know it’s a silly question but I have this question.
Thanks in advance.
(Edit) I managed to solve the problem but when I send the message it plays the code too!
#private mensagem
def mensagemprivate(self, message, name_sender, to=''):
if re.findall('/sms .*', message):
self.post(message=message)
elif '/sms' in message:
t_mensagemprivate = threading.Thread(target=self.mensagemprivate, args=(message, name_sender, id_sender))
t_mensagemprivate.start()
Do not post code as image; the site has code support, just do the [tour] to better understand.
– Woss
Seriously nobody knows how to help me how I can get this /sms out of the way .... ;~;
– user109946