lunarflu HF staff commited on
Commit
88c0b0c
1 Parent(s): 29f983f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +22 -22
app.py CHANGED
@@ -28,34 +28,13 @@ gspread_bot = gspread.service_account(filename='service_account.json')
28
  worksheet = gspread_bot.open("levelbot").sheet1
29
  """"""
30
  bot_ids = [1136614989411655780, 1166392942387265536, 1158038249835610123, 1130774761031610388, 1155489509518098565, 1155169841276260546, 1152238037355474964, 1154395078735953930]
31
-
32
  """"""
33
 
34
  @bot.event
35
  async def on_ready():
36
  print(f'Logged in as {bot.user.name}')
37
  print(f"XP_PER_MESSAGE: {XP_PER_MESSAGE}")
38
- guild = bot.get_guild(879548962464493619)
39
- print(guild)
40
- lvl1 = guild.get_role(1171861537699397733)
41
- lvl2 = guild.get_role(1171861595115245699)
42
- lvl3 = guild.get_role(1171861626715115591)
43
- lvl4 = guild.get_role(1171861657975259206)
44
- lvl5 = guild.get_role(1171861686580412497)
45
- lvl6 = guild.get_role(1171861900301172736)
46
- lvl7 = guild.get_role(1171861936258941018)
47
- lvl8 = guild.get_role(1171861968597024868)
48
- lvl9 = guild.get_role(1171862009982242836)
49
- lvl10 = guild.get_role(1164188093713223721)
50
- lvl11 = guild.get_role(1171524944354607104)
51
- lvl12 = guild.get_role(1171524990257082458)
52
- lvl13 = guild.get_role(1171525021928263791)
53
- lvl14 = guild.get_role(1171525062201966724)
54
- lvl15 = guild.get_role(1171525098465918996)
55
- lvls = {
56
- 1: lvl1, 2: lvl2, 3: lvl3, 4: lvl4, 5: lvl5, 6: lvl6, 7: lvl7, 8: lvl8, 9: lvl9, 10: lvl10,
57
- 11: lvl11, 12: lvl12, 13: lvl13, 14: lvl14, 15: lvl15,
58
- }
59
 
60
 
61
 
@@ -71,6 +50,27 @@ def calculate_xp(level):
71
 
72
  async def add_exp(member):
73
  try:
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
74
  #if member.id == 811235357663297546:
75
  # does a record already exist?
76
  cell = worksheet.find(str(member.id))
 
28
  worksheet = gspread_bot.open("levelbot").sheet1
29
  """"""
30
  bot_ids = [1136614989411655780, 1166392942387265536, 1158038249835610123, 1130774761031610388, 1155489509518098565, 1155169841276260546, 1152238037355474964, 1154395078735953930]
 
31
  """"""
32
 
33
  @bot.event
34
  async def on_ready():
35
  print(f'Logged in as {bot.user.name}')
36
  print(f"XP_PER_MESSAGE: {XP_PER_MESSAGE}")
37
+
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
38
 
39
 
40
 
 
50
 
51
  async def add_exp(member):
52
  try:
53
+ guild = bot.get_guild(879548962464493619)
54
+ print(guild)
55
+ lvl1 = guild.get_role(1171861537699397733)
56
+ lvl2 = guild.get_role(1171861595115245699)
57
+ lvl3 = guild.get_role(1171861626715115591)
58
+ lvl4 = guild.get_role(1171861657975259206)
59
+ lvl5 = guild.get_role(1171861686580412497)
60
+ lvl6 = guild.get_role(1171861900301172736)
61
+ lvl7 = guild.get_role(1171861936258941018)
62
+ lvl8 = guild.get_role(1171861968597024868)
63
+ lvl9 = guild.get_role(1171862009982242836)
64
+ lvl10 = guild.get_role(1164188093713223721)
65
+ lvl11 = guild.get_role(1171524944354607104)
66
+ lvl12 = guild.get_role(1171524990257082458)
67
+ lvl13 = guild.get_role(1171525021928263791)
68
+ lvl14 = guild.get_role(1171525062201966724)
69
+ lvl15 = guild.get_role(1171525098465918996)
70
+ lvls = {
71
+ 1: lvl1, 2: lvl2, 3: lvl3, 4: lvl4, 5: lvl5, 6: lvl6, 7: lvl7, 8: lvl8, 9: lvl9, 10: lvl10,
72
+ 11: lvl11, 12: lvl12, 13: lvl13, 14: lvl14, 15: lvl15,
73
+ }
74
  #if member.id == 811235357663297546:
75
  # does a record already exist?
76
  cell = worksheet.find(str(member.id))