added double barrel shotgun
This commit is contained in:
@@ -162,7 +162,6 @@ cython_debug/
|
||||
# token
|
||||
/discordtoken
|
||||
#images
|
||||
/Reuse/images
|
||||
Reuse/images/legend.png
|
||||
Reuse/images/player_weapons_used.png
|
||||
Reuse/images/leaderboard.png
|
||||
|
||||
@@ -13,7 +13,9 @@ def getleaderboard(board:str, weaponid="", server="", mapid = "", gamemodeid = "
|
||||
board = "max_distance"
|
||||
|
||||
if(board.lower() == "kd"):
|
||||
if(weaponid != ""):
|
||||
handler = lambda p : response[p]['kills'] / max(response[p]["deaths_while_equipped"], 1)
|
||||
handler = lambda p : response[p]['kills'] / max(response[p]["deaths"], 1)
|
||||
elif(board.lower() == "avgd"):
|
||||
handler = lambda p : response[p]['total_distance'] / max(response[p]["kills"], 1)
|
||||
else:
|
||||
|
||||
+2
-1
@@ -44,7 +44,8 @@ def getweaponid(givenweapon):
|
||||
"p2016": "mp_weapon_semipistol",
|
||||
"arc grenade": "mp_weapon_grenade_emp",
|
||||
"hemlok": "mp_weapon_hemlok",
|
||||
"phase shift": "phase_shift"
|
||||
"phase shift": "phase_shift",
|
||||
"double barrel shotgun": "mp_weapon_shotgun_doublebarrel"
|
||||
}
|
||||
|
||||
weaponid = ""
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 4.7 KiB |
@@ -52,7 +52,7 @@ class SlashLeaderboard(commands.Cog):
|
||||
@leaderboard.autocomplete("weapon")
|
||||
async def autocomplete_weapon(self, interaction: discord.Interaction, current: str) -> list[app_commands.Choice[str]]:
|
||||
data = []
|
||||
weaponlist = ['execution', 'car', 'charge rifle', 'double take', 'epg', 'volt', 'lstar', 'r97', 'r-201', 'smart pistol', 'kraber', 'flatline', 're-45 auto', 'alternator', 'frag grenade', 'g2', 'spitfire', 'smr', 'softball', 'firestar', 'melee', 'mastiff', 'mgl', 'r-101', 'wingman', 'invalid', 'thunderbolt', 'dmr', 'electric smoke', 'cold war', 'satchel', 'eva-8 auto', 'mozambique', 'wingman elite', 'gravity star', 'pulse blade', 'archer', 'outOfBounds', 'mind crime', 'devotion', 'fall', 'p2016', 'arc grenade', 'hemlok', 'phase shift']
|
||||
weaponlist = ['execution', 'car', 'charge rifle', 'double take', 'epg', 'volt', 'lstar', 'r97', 'r-201', 'smart pistol', 'kraber', 'flatline', 're-45 auto', 'alternator', 'frag grenade', 'g2', 'spitfire', 'smr', 'softball', 'firestar', 'melee', 'mastiff', 'mgl', 'r-101', 'wingman', 'invalid', 'thunderbolt', 'dmr', 'electric smoke', 'cold war', 'satchel', 'eva-8 auto', 'mozambique', 'wingman elite', 'gravity star', 'pulse blade', 'archer', 'outOfBounds', 'mind crime', 'devotion', 'fall', 'p2016', 'arc grenade', 'hemlok', 'phase shift', 'double barrel shotgun']
|
||||
for weapon_choice in weaponlist:
|
||||
if(current.lower() in weapon_choice.lower()):
|
||||
data.append(app_commands.Choice(name=weapon_choice, value=weapon_choice))
|
||||
|
||||
@@ -79,7 +79,7 @@ class SlashStats(commands.Cog):
|
||||
@stats.autocomplete("weapon")
|
||||
async def autocomplete_weapon(self, interaction: discord.Interaction, current: str) -> list[app_commands.Choice[str]]:
|
||||
data = []
|
||||
weaponlist = ['execution', 'car', 'charge rifle', 'double take', 'epg', 'volt', 'lstar', 'r97', 'r-201', 'smart pistol', 'kraber', 'flatline', 're-45 auto', 'alternator', 'frag grenade', 'g2', 'spitfire', 'smr', 'softball', 'firestar', 'melee', 'mastiff', 'mgl', 'r-101', 'wingman', 'invalid', 'thunderbolt', 'dmr', 'electric smoke', 'cold war', 'satchel', 'eva-8 auto', 'mozambique', 'wingman elite', 'gravity star', 'pulse blade', 'archer', 'outOfBounds', 'mind crime', 'devotion', 'fall', 'p2016', 'arc grenade', 'hemlok', 'phase shift']
|
||||
weaponlist = ['execution', 'car', 'charge rifle', 'double take', 'epg', 'volt', 'lstar', 'r97', 'r-201', 'smart pistol', 'kraber', 'flatline', 're-45 auto', 'alternator', 'frag grenade', 'g2', 'spitfire', 'smr', 'softball', 'firestar', 'melee', 'mastiff', 'mgl', 'r-101', 'wingman', 'invalid', 'thunderbolt', 'dmr', 'electric smoke', 'cold war', 'satchel', 'eva-8 auto', 'mozambique', 'wingman elite', 'gravity star', 'pulse blade', 'archer', 'outOfBounds', 'mind crime', 'devotion', 'fall', 'p2016', 'arc grenade', 'hemlok', 'phase shift', 'double barrel shotgun']
|
||||
for weapon_choice in weaponlist:
|
||||
if(current.lower() in weapon_choice.lower()):
|
||||
data.append(app_commands.Choice(name=weapon_choice, value=weapon_choice))
|
||||
|
||||
Reference in New Issue
Block a user