File tree Expand file tree Collapse file tree 1 file changed +6
-8
lines changed Expand file tree Collapse file tree 1 file changed +6
-8
lines changed Original file line number Diff line number Diff line change 77async def on_clan_member_join (member , clan ):
88 print ("{} just joined our clan {}!" .format (member .name , clan .name ))
99
10-
10+ @ client . event
1111async def on_clan_member_leave (member , clan ):
1212 print ("Oh no! {} just left our clan {}!" .format (member .name , clan .name ))
1313
14-
15- async def when_someone_attacks (attack , war ):
14+ @ client . event
15+ async def on_war_attack (attack , war ):
1616 print (
1717 "{} just attacked {} for {} stars! It was a {} war." .format (
1818 attack .attacker .name , attack .defedender .name , attack .stars , war .type
1919 )
2020 )
2121
22-
23- client .add_events (on_clan_member_join , function_dicts = {"on_war_attack" : when_someone_attacks })
24- client .add_clan_update ("tag" , "another tag" , retry_interval = 30 )
25- client .add_war_update ("clan tag" , retry_interval = 60 )
26- client .start_updates ("all" )
22+ tags = ["#tag" , "#tag2" , "#tag3" ]
23+ client .add_clan_update (tags , retry_interval = 30 )
24+ client .add_war_update (tags , retry_interval = 300 )
2725
2826client .run_forever ()
You can’t perform that action at this time.
0 commit comments