commit
a552362869
File diff suppressed because it is too large
Load Diff
@ -1,106 +0,0 @@
|
||||
AUTHOR: bobloy
|
||||
https://www.youtube.com/watch?v=nfjiy-NX5b0:
|
||||
- flashbang
|
||||
https://www.youtube.com/watch?v=mJCE7s4W4IE:
|
||||
- starting round
|
||||
- round start
|
||||
- start round
|
||||
https://www.youtube.com/watch?v=XfLGi4cPu0Y:
|
||||
- select team
|
||||
- team select
|
||||
https://www.youtube.com/watch?v=b6ScVgFs-DQ:
|
||||
- desert eagle
|
||||
- deagle
|
||||
https://www.youtube.com/watch?v=JnHm-rn199Y:
|
||||
- planted bomb
|
||||
- bomb planted
|
||||
- bomb plant
|
||||
- plant bomb
|
||||
https://www.youtube.com/watch?v=3wztV24tbVU:
|
||||
- defusing bomb
|
||||
- defuse bomb
|
||||
- bomb defuse
|
||||
- bomb defusing
|
||||
https://www.youtube.com/watch?v=mpY9poBVje4:
|
||||
- lobby
|
||||
https://www.youtube.com/watch?v=zMT4ovCN7gk:
|
||||
- usp-s
|
||||
- usp s
|
||||
- usps
|
||||
https://www.youtube.com/watch?v=oI5Ww7y2aUQ:
|
||||
- gut knife
|
||||
https://www.youtube.com/watch?v=Dqmyxnx-OaQ:
|
||||
- ak47
|
||||
- ak 47
|
||||
https://www.youtube.com/watch?v=Ny4hGdziZP4:
|
||||
- hitmarker
|
||||
- hit
|
||||
- hitmaker
|
||||
- marker
|
||||
https://www.youtube.com/watch?v=vYUynDKM1Yw:
|
||||
- awp
|
||||
https://www.youtube.com/watch?v=52etXKmbQRM:
|
||||
- butterfly knife
|
||||
https://www.youtube.com/watch?v=99o4eyq0SzY:
|
||||
- won round
|
||||
- round won
|
||||
- win round
|
||||
- round win
|
||||
https://www.youtube.com/watch?v=V5tv1ZzqI_U:
|
||||
- lost round
|
||||
- round lost
|
||||
- lose round
|
||||
- round loss
|
||||
https://www.youtube.com/watch?v=1hI25OPdim0:
|
||||
- flashbang toss
|
||||
- toss flashbang
|
||||
- throwing flashbang
|
||||
- throw flashbang
|
||||
- flashbang throwing
|
||||
- flashbang throw
|
||||
- tossing flashbang
|
||||
- flashbang tossing
|
||||
https://www.youtube.com/watch?v=oML0z2Aj_D4:
|
||||
- firegrenade toss
|
||||
- toss firegrenade
|
||||
- throwing firegrenade
|
||||
- throw firegrenade
|
||||
- firegrenade throwing
|
||||
- firegrenade throw
|
||||
- tossing firegrenade
|
||||
- firegrenade tossing
|
||||
- fire grenade toss
|
||||
- toss fire grenade
|
||||
- throwing fire grenade
|
||||
- throw fire grenade
|
||||
- fire grenade throwing
|
||||
- fire grenade throw
|
||||
- tossing fire grenade
|
||||
- fire grenade tossing
|
||||
https://www.youtube.com/watch?v=9otQ9OLfaQc:
|
||||
- grenade out
|
||||
https://www.youtube.com/watch?v=tFA-8Vc32Kg:
|
||||
- famas
|
||||
https://www.youtube.com/watch?v=MdI1u8oXKZw:
|
||||
- awp zoom
|
||||
- zoom awp
|
||||
- awp scope
|
||||
- scope awp
|
||||
https://www.youtube.com/watch?v=6NiZhX4h32Q:
|
||||
- c4
|
||||
https://www.youtube.com/watch?v=3N0NxsyWPiY:
|
||||
- planting c4
|
||||
- c4 planting
|
||||
- plant c4
|
||||
- c4 plant
|
||||
https://www.youtube.com/watch?v=XLaJIXZ5QUc:
|
||||
- awp
|
||||
https://www.youtube.com/watch?v=DmuK9Wml88E:
|
||||
- P90
|
||||
https://www.youtube.com/watch?v=t1Ky_TbDXHY:
|
||||
- smoke
|
||||
https://www.youtube.com/watch?v=sJvdTbejDRY:
|
||||
- kill bonus
|
||||
https://www.youtube.com/watch?v=DYWi8qdvWCk:
|
||||
- AK47
|
||||
- AK 47
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -1,4 +0,0 @@
|
||||
https://www.youtube.com/watch?v=hfyE220BsD0:
|
||||
- holiday
|
||||
https://www.youtube.com/watch?v=Hh3U9iPKeXQ:
|
||||
- sultans of swing
|
@ -1,4 +0,0 @@
|
||||
https://www.youtube.com/watch?v=Hi1kUdreiWk:
|
||||
- Jinx
|
||||
https://www.youtube.com/watch?v=PNYHFluhOGI:
|
||||
- Teemo
|
@ -0,0 +1,125 @@
|
||||
AUTHOR: Lazar
|
||||
https://youtu.be/6OejNXrGkK0:
|
||||
- Anaheim Ducks
|
||||
- Anaheim
|
||||
- Ducks
|
||||
https://youtu.be/RbUxSPoU9Yg:
|
||||
- Arizona Coyotes
|
||||
- Arizona
|
||||
- Coyotes
|
||||
https://youtu.be/DsI0PgWADks:
|
||||
- Boston Bruins
|
||||
- Boston
|
||||
- Bruins
|
||||
https://youtu.be/hjFTd3MJOHc:
|
||||
- Buffalo Sabres
|
||||
- Buffalo
|
||||
- Sabres
|
||||
https://youtu.be/sn1PliBCRDY:
|
||||
- Calgary Flames
|
||||
- Calgary
|
||||
- Flames
|
||||
https://youtu.be/3exZm6Frd18:
|
||||
- Carolina Hurricanes
|
||||
- Carolina
|
||||
- Hurricanes
|
||||
https://youtu.be/sBeXPMkqR80:
|
||||
- Chicago Blackhawks
|
||||
- Chicago
|
||||
- Blackhawks
|
||||
https://youtu.be/MARxzs_vCPI:
|
||||
- Colorado Avalanche
|
||||
- Colorado
|
||||
- Avalanche
|
||||
https://youtu.be/6yYbQfOWw4k:
|
||||
- Columbus Blue Jackets
|
||||
- Columbus
|
||||
- Blue Jackets
|
||||
https://youtu.be/Af8_9NP5lyw:
|
||||
- Dallas
|
||||
- Stars
|
||||
- Dallas Stars
|
||||
https://youtu.be/JflfvLvY7ks:
|
||||
- Detroit Red Wings
|
||||
- Detroit
|
||||
- Red wings
|
||||
https://youtu.be/xc422k5Tcqc:
|
||||
- Edmonton Oilers
|
||||
- Edmonton
|
||||
- Oilers
|
||||
https://youtu.be/Dm1bjUB9HLE:
|
||||
- Florida Panthers
|
||||
- Florida
|
||||
- Panthers
|
||||
https://youtu.be/jSgd3aIepY4:
|
||||
- Los Angeles Kings
|
||||
- Los Angeles
|
||||
- Kings
|
||||
https://youtu.be/4Pj8hWPR9VI:
|
||||
- Minnesota Wild
|
||||
- Minnesota
|
||||
- Wild
|
||||
https://youtu.be/rRGlUFWEBMk:
|
||||
- Montreal Canadiens
|
||||
- Montreal
|
||||
- Canadiens
|
||||
https://youtu.be/fHTehdlMwWQ:
|
||||
- Nashville Predators
|
||||
- Nashville
|
||||
- Predators
|
||||
https://youtu.be/4q0eNg-AbrQ:
|
||||
- New Jersey Devils
|
||||
- New Jersey
|
||||
- Devils
|
||||
https://youtu.be/ZC514zGrL80:
|
||||
- New York
|
||||
- Islanders
|
||||
- New York Islanders
|
||||
https://youtu.be/Zzfks2A2n38:
|
||||
- New York Rangers
|
||||
- New York
|
||||
- Rangers
|
||||
https://youtu.be/fHlWxPRNVBc:
|
||||
- Ottawa Senators
|
||||
- Ottawa
|
||||
- Senators
|
||||
https://youtu.be/0LsXpMiVD1E:
|
||||
- Philadelphia Flyers
|
||||
- Philadelphia
|
||||
- Flyers
|
||||
https://youtu.be/Llw3adcNuzI:
|
||||
- Pittsburgh Penguins
|
||||
- Pittsburgh
|
||||
- Penguins
|
||||
https://youtu.be/NZqSBkmpbLw:
|
||||
- San Jose Sharks
|
||||
- San Jose
|
||||
- Sharks
|
||||
https://youtu.be/Q23TDOJsY1s:
|
||||
- St. Louis Blues
|
||||
- St. Louis
|
||||
- Blues
|
||||
https://youtu.be/bdhDXxM20iM:
|
||||
- Tampa Bay Lightning
|
||||
- Tampa Bay
|
||||
- Lightning
|
||||
https://youtu.be/2cyekaemZgs:
|
||||
- Toronto Maple Leafs
|
||||
- Toronto
|
||||
- Maple Leafs
|
||||
https://youtu.be/CPozN-ZHpAo:
|
||||
- Vancouver
|
||||
- Canucks
|
||||
- Vancouver Canucks
|
||||
https://youtu.be/zheGI316WXg:
|
||||
- Vegas Golden Knights
|
||||
- Vegas
|
||||
- Golden Knights
|
||||
https://youtu.be/BH_CC1RxtfU:
|
||||
- Washington Capitals
|
||||
- Washington
|
||||
- Capitals
|
||||
https://youtu.be/3gcahU_i9WE:
|
||||
- Winnipeg Jets
|
||||
- Winnipeg
|
||||
- Jets
|
@ -0,0 +1,5 @@
|
||||
from .infochannel import InfoChannel
|
||||
|
||||
|
||||
def setup(bot):
|
||||
bot.add_cog(InfoChannel(bot))
|
@ -0,0 +1,18 @@
|
||||
{
|
||||
"author": [
|
||||
"Bobloy"
|
||||
],
|
||||
"bot_version": [
|
||||
3,
|
||||
0,
|
||||
0
|
||||
],
|
||||
"description": "Create a channel with updating server info",
|
||||
"hidden": false,
|
||||
"install_msg": "Thank you for installing InfoChannel. Get started with `[p]load infochannel`, then `[p]help InfoChannel`",
|
||||
"short": "Updating server info channel",
|
||||
"tags": [
|
||||
"bobloy",
|
||||
"utils"
|
||||
]
|
||||
}
|
@ -0,0 +1,215 @@
|
||||
from typing import Any
|
||||
import discord
|
||||
|
||||
from redbot.core import Config, commands, checks
|
||||
from redbot.core.bot import Red
|
||||
|
||||
Cog: Any = getattr(commands, "Cog", object)
|
||||
listener = getattr(commands.Cog, "listener", None) # Trusty + Sinbad
|
||||
if listener is None:
|
||||
|
||||
def listener(name=None):
|
||||
return lambda x: x
|
||||
|
||||
|
||||
class InfoChannel(Cog):
|
||||
"""
|
||||
Create a channel with updating server info
|
||||
|
||||
Less important information about the cog
|
||||
"""
|
||||
|
||||
def __init__(self, bot: Red):
|
||||
self.bot = bot
|
||||
self.config = Config.get_conf(
|
||||
self, identifier=731101021116710497110110101108, force_registration=True
|
||||
)
|
||||
|
||||
default_guild = {
|
||||
"channel_id": None,
|
||||
"botchannel_id": None,
|
||||
"onlinechannel_id": None,
|
||||
"member_count": True,
|
||||
"bot_count": False,
|
||||
"online_count": False,
|
||||
}
|
||||
|
||||
self.config.register_guild(**default_guild)
|
||||
|
||||
@commands.command()
|
||||
@checks.admin()
|
||||
async def infochannel(self, ctx: commands.Context):
|
||||
"""
|
||||
Toggle info channel for this server
|
||||
"""
|
||||
|
||||
def check(m):
|
||||
return (
|
||||
m.content.upper() in ["Y", "YES", "N", "NO"]
|
||||
and m.channel == ctx.channel
|
||||
and m.author == ctx.author
|
||||
)
|
||||
|
||||
guild: discord.Guild = ctx.guild
|
||||
channel_id = await self.config.guild(guild).channel_id()
|
||||
if channel_id is not None:
|
||||
channel: discord.VoiceChannel = guild.get_channel(channel_id)
|
||||
else:
|
||||
channel: discord.VoiceChannel = None
|
||||
|
||||
if channel_id is not None and channel is None:
|
||||
await ctx.send("Info channel has been deleted, recreate it?")
|
||||
elif channel_id is None:
|
||||
await ctx.send("Enable info channel on this server?")
|
||||
else:
|
||||
await ctx.send("Do you wish to delete current info channels?")
|
||||
|
||||
msg = await self.bot.wait_for("message", check=check)
|
||||
|
||||
if msg.content.upper() in ["N", "NO"]:
|
||||
await ctx.send("Cancelled")
|
||||
return
|
||||
|
||||
if channel is None:
|
||||
await self.make_infochannel(guild)
|
||||
else:
|
||||
await self.delete_infochannel(guild, channel)
|
||||
|
||||
if not await ctx.tick():
|
||||
await ctx.send("Done!")
|
||||
|
||||
@commands.group()
|
||||
@checks.admin()
|
||||
async def infochannelset(self, ctx: commands.Context):
|
||||
"""
|
||||
Toggle different types of infochannels
|
||||
"""
|
||||
|
||||
@infochannelset.command(name="botcount")
|
||||
async def _infochannelset_botcount(self, ctx: commands.Context, enabled: bool = None):
|
||||
"""
|
||||
Toggle an infochannel that shows the amount of bots in the server
|
||||
"""
|
||||
guild = ctx.guild
|
||||
if enabled is None:
|
||||
enabled = not await self.config.guild(guild).bot_count()
|
||||
await self.config.guild(guild).bot_count.set(enabled)
|
||||
if enabled:
|
||||
await ctx.send("InfoChannel for bot count has been enabled.")
|
||||
else:
|
||||
await ctx.send("InfoChannel for bot count has been disabled.")
|
||||
|
||||
@infochannelset.command(name="onlinecount")
|
||||
async def _infochannelset_onlinecount(self, ctx: commands.Context, enabled: bool = None):
|
||||
"""
|
||||
Toggle an infochannel that shows the amount of online users in the server
|
||||
"""
|
||||
guild = ctx.guild
|
||||
if enabled is None:
|
||||
enabled = not await self.config.guild(guild).online_count()
|
||||
await self.config.guild(guild).online_count.set(enabled)
|
||||
if enabled:
|
||||
await ctx.send("InfoChannel for online user count has been enabled.")
|
||||
else:
|
||||
await ctx.send("InfoChannel for online user count has been disabled.")
|
||||
|
||||
async def make_infochannel(self, guild: discord.Guild):
|
||||
botcount = await self.config.guild(guild).bot_count()
|
||||
onlinecount = await self.config.guild(guild).online_count()
|
||||
overwrites = {
|
||||
guild.default_role: discord.PermissionOverwrite(connect=False),
|
||||
guild.me: discord.PermissionOverwrite(manage_channels=True, connect=True),
|
||||
}
|
||||
|
||||
channel = await guild.create_voice_channel(
|
||||
"Placeholder", reason="InfoChannel make", overwrites=overwrites
|
||||
)
|
||||
await self.config.guild(guild).channel_id.set(channel.id)
|
||||
|
||||
if botcount:
|
||||
botchannel = await guild.create_voice_channel(
|
||||
"Placeholder", reason="InfoChannel botcount", overwrites=overwrites
|
||||
)
|
||||
await self.config.guild(guild).botchannel_id.set(botchannel.id)
|
||||
if onlinecount:
|
||||
onlinechannel = await guild.create_voice_channel(
|
||||
"Placeholder", reason="InfoChannel onlinecount", overwrites=overwrites
|
||||
)
|
||||
await self.config.guild(guild).onlinechannel_id.set(onlinechannel.id)
|
||||
|
||||
await self.update_infochannel(guild)
|
||||
|
||||
async def delete_infochannel(self, guild: discord.Guild, channel: discord.VoiceChannel):
|
||||
guild_data = await self.config.guild(guild).all()
|
||||
botchannel_id = guild_data["botchannel_id"]
|
||||
onlinechannel_id = guild_data["onlinechannel_id"]
|
||||
botchannel: discord.VoiceChannel = guild.get_channel(botchannel_id)
|
||||
onlinechannel: discord.VoiceChannel = guild.get_channel(onlinechannel_id)
|
||||
channel_id = guild_data["channel_id"]
|
||||
channel: discord.VoiceChannel = guild.get_channel(channel_id)
|
||||
await channel.delete(reason="InfoChannel delete")
|
||||
if botchannel_id is not None:
|
||||
await botchannel.delete(reason="InfoChannel delete")
|
||||
if onlinechannel_id is not None:
|
||||
await onlinechannel.delete(reason="InfoChannel delete")
|
||||
await self.config.guild(guild).clear()
|
||||
|
||||
async def update_infochannel(self, guild: discord.Guild):
|
||||
guild_data = await self.config.guild(guild).all()
|
||||
botcount = guild_data["bot_count"]
|
||||
onlinecount = guild_data["online_count"]
|
||||
|
||||
# Gets count of bots
|
||||
bots = lambda x: x.bot
|
||||
num = len([m for m in guild.members if bots(m)])
|
||||
bot_msg = f"Bots: {num}"
|
||||
|
||||
# Gets count of online users
|
||||
members = guild.member_count
|
||||
offline = len(list(filter(lambda m: m.status is discord.Status.offline, guild.members)))
|
||||
num = members - offline
|
||||
online_msg = f"Online: {num}"
|
||||
|
||||
# Gets count of actual users
|
||||
total = lambda x: not x.bot
|
||||
num = len([m for m in guild.members if total(m)])
|
||||
human_msg = f"Total Humans: {num}"
|
||||
|
||||
channel_id = guild_data["channel_id"]
|
||||
if channel_id is None:
|
||||
return
|
||||
|
||||
botchannel_id = guild_data["botchannel_id"]
|
||||
onlinechannel_id = guild_data["onlinechannel_id"]
|
||||
channel_id = guild_data["channel_id"]
|
||||
channel: discord.VoiceChannel = guild.get_channel(channel_id)
|
||||
botchannel: discord.VoiceChannel = guild.get_channel(botchannel_id)
|
||||
onlinechannel: discord.VoiceChannel = guild.get_channel(onlinechannel_id)
|
||||
|
||||
if guild_data["member_count"]:
|
||||
name = "{} ".format(human_msg)
|
||||
|
||||
await channel.edit(reason="InfoChannel update", name=name)
|
||||
|
||||
if botcount:
|
||||
name = "{} ".format(bot_msg)
|
||||
await botchannel.edit(reason="InfoChannel update", name=name)
|
||||
|
||||
if onlinecount:
|
||||
name = "{} ".format(online_msg)
|
||||
await onlinechannel.edit(reason="InfoChannel update", name=name)
|
||||
|
||||
@listener()
|
||||
async def on_member_join(self, member: discord.Member):
|
||||
await self.update_infochannel(member.guild)
|
||||
|
||||
@listener()
|
||||
async def on_member_remove(self, member: discord.Member):
|
||||
await self.update_infochannel(member.guild)
|
||||
|
||||
@listener()
|
||||
async def on_member_update(self, before: discord.Member, after: discord.Member):
|
||||
onlinecount = await self.config.guild(after.guild).online_count()
|
||||
if onlinecount:
|
||||
if before.status != after.status:
|
||||
await self.update_infochannel(after.guild)
|
@ -1,5 +1,10 @@
|
||||
from redbot.core import data_manager
|
||||
|
||||
from .planttycoon import PlantTycoon
|
||||
|
||||
|
||||
def setup(bot):
|
||||
bot.add_cog(PlantTycoon(bot))
|
||||
async def setup(bot):
|
||||
tycoon = PlantTycoon(bot)
|
||||
data_manager.bundled_data_path(tycoon)
|
||||
await tycoon._load_plants_products() # I can access protected members if I want, linter!!
|
||||
bot.add_cog(tycoon)
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,10 +1,22 @@
|
||||
{
|
||||
"author" : ["Bobloy"],
|
||||
"bot_version" : [3,0,0],
|
||||
"author": [
|
||||
"Bobloy"
|
||||
],
|
||||
"bot_version": [
|
||||
3,
|
||||
0,
|
||||
0
|
||||
],
|
||||
"description": "Cog to prevent reactions on specific messages from certain users",
|
||||
"hidden": true,
|
||||
"install_msg": "Thank you for installing ReactRestrict.",
|
||||
"requirements" : [],
|
||||
"short": "[Incomplete] Prevent reactions",
|
||||
"tags" : ["react", "reaction", "restrict", "tools", "utils", "bobloy"]
|
||||
"tags": [
|
||||
"react",
|
||||
"reaction",
|
||||
"restrict",
|
||||
"tools",
|
||||
"utils",
|
||||
"bobloy"
|
||||
]
|
||||
}
|
Loading…
Reference in new issue