Gives permission to the worshipper role

This commit is contained in:
deflax 2025-02-05 22:29:39 +00:00
parent c838afc2c9
commit c5868750b4
2 changed files with 9 additions and 4 deletions

View file

@ -37,4 +37,8 @@ ffmpeg -i brooklynsfinest_clip_1080p.mp4 \
-hls_segment_type mpegts \
-hls_segment_filename stream_%v/data%02d.ts \
-master_pl_name master.m3u8 \
-var_stream_map "v:0,a:0 v:1,a:1 v:2,a:2" stream_%v.m3u8
-var_stream_map "v:0,a:0 v:1,a:1 v:2,a:2" stream_%v.m3u8
ffmpeg -i /dev/video0 -i /dev/video2 -stream_loop -1 -re -i audio.mp3 -filter_complex "[0][1]overlay=enable='lt(mod(t,60),30)'[v]" -map "[v]" -map 2:a -c:v libx264 -b:v 4000k -maxrate 4000k -bufsize 8000k -g 50 -c:a aac -f flv rtmp://youtube
ffmpeg -i source.mp4 -s 640x360 -hls_list_size 30 -hls_flags delete_segments+append_list+omit_endlist -f hls out.m3u8

View file

@ -24,6 +24,7 @@ intents.message_content = True
# Discord client
bot = Bot(command_prefix=".", intents=intents)
worshipper_role_name = "worshipper"
# Scheduler
scheduler = AsyncIOScheduler()
@ -44,7 +45,7 @@ async def on_ready():
scheduler.start()
@bot.command(name='hello', help='Say hello to the bot')
@has_permissions(administrator=True)
@has_role(worshipper_role_name)
async def hello(ctx):
author_name = ctx.author.name
await ctx.channel.send(f'hi, `{author_name}` :blush:')
@ -52,8 +53,8 @@ async def hello(ctx):
@hello.error
async def hello_error(ctx, error):
if isinstance(error, CheckFailure):
msg = "{} access denied!".format(ctx.message.author.mention)
await ctx.send(msg)
author_name = ctx.author.name
await ctx.channel.send(f'do I know you, `{}`?')
@bot.command(name='epg', help='Lists scheduled streams')
async def epg(ctx):