2022-11-07 17:30:40 +01:00
|
|
|
from flask import current_app
|
2023-03-20 17:16:17 +01:00
|
|
|
from tlapbot.owncast_requests import send_chat
|
2022-11-07 17:30:40 +01:00
|
|
|
|
|
|
|
|
|
|
|
def send_help():
|
|
|
|
message = []
|
2024-02-06 18:18:15 +01:00
|
|
|
message.append("Tlapbot gives you points for being in chat, and then allows you to spend those points. <br>")
|
|
|
|
message.append(f"People connected to chat receive {current_app.config['POINTS_AMOUNT_GIVEN']} points every {current_app.config['POINTS_CYCLE_TIME']} seconds. <br>")
|
|
|
|
message.append("You can see your points and recent redeems in the Tlapbot dashboard. Look for a button to click under the stream window. <br>")
|
2024-02-04 18:09:47 +01:00
|
|
|
message.append("""Tlapbot commands: <br>
|
|
|
|
!help to see this help message. <br>
|
2024-02-06 18:18:15 +01:00
|
|
|
!points to see your points. <br>"""
|
2022-11-07 17:30:40 +01:00
|
|
|
)
|
|
|
|
if current_app.config['LIST_REDEEMS']:
|
2024-02-06 18:18:15 +01:00
|
|
|
message.append("Active redeems: <br>")
|
2022-11-07 17:30:40 +01:00
|
|
|
for redeem, redeem_info in current_app.config['REDEEMS'].items():
|
|
|
|
if 'info' in redeem_info:
|
2024-02-06 18:18:15 +01:00
|
|
|
message.append(f"!{redeem} for {redeem_info['price']} points. {redeem_info['info']} <br>")
|
2022-11-07 17:30:40 +01:00
|
|
|
else:
|
2024-02-06 18:18:15 +01:00
|
|
|
message.append(f"!{redeem} for {redeem_info['price']} points. <br>")
|
2022-11-09 15:14:10 +01:00
|
|
|
else:
|
|
|
|
message.append("Check the dashboard for a list of currently active redeems.")
|
2022-11-22 11:33:05 +01:00
|
|
|
send_chat(''.join(message))
|