mirror of
https://gitlab.com/oloturia/damastodon.git
synced 2025-01-07 22:17:15 +01:00
fixing refusing a match
This commit is contained in:
parent
b50152dbbd
commit
a86346feb2
1 changed files with 7 additions and 2 deletions
|
@ -75,8 +75,13 @@ def check_message(notification):
|
||||||
mastodon.status_post("◾: @"+account+" ◽: @"+challenger+" \nturn ◽\n"+dama.draw_checkerboard(board,space,white_norm,white_knight,black_norm,black_knight,empty,column,frstrow),visibility="direct")
|
mastodon.status_post("◾: @"+account+" ◽: @"+challenger+" \nturn ◽\n"+dama.draw_checkerboard(board,space,white_norm,white_knight,black_norm,black_knight,empty,column,frstrow),visibility="direct")
|
||||||
return
|
return
|
||||||
elif content.split(" ")[1].lower() == "no":
|
elif content.split(" ")[1].lower() == "no":
|
||||||
os.remove(save_position+content.split(" ")[0][1:])
|
try:
|
||||||
mastodon.status_post(account+" you cancelled the challenge from "+content.split(" ")[0],visibility="direct")
|
challenger = notification["status"]["mentions"][1]["acct"]
|
||||||
|
except:
|
||||||
|
mastodon.status_post("Hello @"+account+" \n your request is not valid",visibility="direct")
|
||||||
|
return
|
||||||
|
os.remove(save_position+challenger)
|
||||||
|
mastodon.status_post(account+" you cancelled the challenge from "+challenger,visibility="direct")
|
||||||
return
|
return
|
||||||
else:
|
else:
|
||||||
mastodon.status_post("Hello @"+account+" \nI can't understand your command or you're not in a match.\nWrite HELP to see the list of available commands.",visibility="direct")
|
mastodon.status_post("Hello @"+account+" \nI can't understand your command or you're not in a match.\nWrite HELP to see the list of available commands.",visibility="direct")
|
||||||
|
|
Loading…
Reference in a new issue