Skip to content

Overrides for Brave Bot @ Development Guide:

Configuration made easy. Made to be easy & simple. All done in your / Brave Bot's config.yml file. There are many overrides in Brave Bot. Work on adding more is always happening. How many will we have? Well technically there is no limit and we are always open to any new override ideas.

Available Overrides:

  1. Pro Override
  2. Topia Override
  3. Forked Mode Override
  4. Logs Override
  5. ProButtons Override
  6. Pro Bonuses Override
  7. Applications Override
  8. ProRole Override
  9. Gambling Commands Override
  10. Coins Every Message Override
  11. SMN (Set My Nick) Command Override
  12. GitLab Integration Override
  13. ProWelcome Override
  14. Pro GlobaLogs Override
  15. DevBlogs Override
  16. Setup Database Boot Mode Override
  17. Pro for Users Override
  18. Pro for Servers Override
  19. Sentry Integration Override
  20. Production Mode Override
  21. Tips Override
  22. ProButton Previews Override
  23. Topia Insights Override
  24. Topia VAT Override
  25. Pro No VAT Added Override
  26. Profile Suspensions Override
  27. Public Bot Override
  28. Pay To Play Fee Override
  29. Nuke Command Restrictions Override

Override Impact Types:

Overrides can impact the user expirence. To ensure users are well informed and are not overwhelmed there are only 2 Impact Types.

Impact Type: Symbol: Description:
Partial P or (P) Partially impacts the command. The command may return an ephemeral error message.
Full F or (F) Command will not run and will just return an ephemeral error message.

For ease of use we do not really want to add any more Override Impact Types (OITs). This is because Brave Bot is already quite big and complex.

Note

Partial Impact Type Override do not nesccarily return an ephemeral error message.

How to view your Bot's Overrides Configuration:

Do /help and select the help-extra named: Overrides.

Developer Context:

  • When an override has been set to: True, this means the override/system has been enabled.
    • To enable an override, set it to: True unless it is a semi-automatic override.
  • When an override has been set to: False, this means the override/system has been disabled.
    • To disable an override, set it to: False unless it is a semi-automatic override.

Checking an Override:

When checking an override you must use the respective function in the utils directory.

  • Topia related Override checks will be found in utils/topia.py
  • Pro related Override checks will be found in utils/pro.py
  • Other Override checks will be found in utils/overrides.py

There are only 2 Overrides that do not have a function:

  1. Set my Nickname Command Override.
  2. Fork Override.

Notes:

ProButtons Override:

For a ProButton to send, you need both the ProButtons Override and the Pro Override to be enabled. Having just one of the overrides enabled will not allow the ProButton to be sent.

Logs Override:

The Logs Override requires your to fill the Logs Channel ID to be filled. (Integer only)

GlobaLogs:

Certain aspects of our Bot are require logging. But this logging is optional for the developer. It is used in our Core Moderation Commands for Transparency (Click Here to Learn More). It is also used for certain Fun Commands, Unknown Error Logs and Reboot Logs.

Note

In your config.yml please ensure you set the field named Logs Channel ID to the Discord Channel ID you want used for GlobaLogs. It is optional and if set to False this override will be set to False regardless.

Pro GlobaLogs Override:

If the Logs Override is set to False. The Pro GlobaLogs Override will also be set to False regardless.

Forked Mode Override:

The Forked Mode Override only has a partial impact on /help. If no extra is selected, the main embed will have a footer telling the user that the bot they are using it is a fork of Brave Bot.

Pro Override:

The Pro Override that checks if there is any Pro Users (User IDs) and Pro Servers (Server IDs) in your config.yml file. The override will automatically decide if the system should be enabled or disabled. Read below to see how and why:

  • If there is IDs (items in the list) in either the pro_users and pro_servers lists then the override will be set to True.
  • If there is no IDs in one list but the other list has IDs. The override will be set to True.
  • If there is no IDs in both lists then the override will be set to False.
  • Even if there is IDs in the both or one list, you can still disable the Pro system with the Pro Override. You can also manually disable the Pro for Users Override and Pro for Servers Override in your config.yml. Please note if you enable all 3 overrides but there is no IDs in both lists the overrides will be set to disabled/off.

Pro Role Override:

Please note that the Pro Role Override requires the following if enabled (set to True):

  1. The Pro Override to be enabled. (Set to True)
  2. The Pro Role ID field to be filled with your "Pro Role's ID".

Warning

The Pro Role ID must be from the same server you have given the ID for the Server ID field.

Topia Override:

For the Topia System to work the following must be fulfilled:

  1. The Topia Override is enabled. (Set to True)
  2. The Setup Database Boot Mode Override is enabled on first boot. (Please disable it upon getting confirmation the database has been set-up. Else the database may reset itself upon re-boot)

  3. If the Topia Override is disabled, a large selection of Brave Bot's Commands will be useless and will not work (they will simply return an ephemeral error message).

  4. Many of Brave Bot's Topia Commands (the ones that have the Topia Override) also have the Pro Override. This is because there is a Pro Perk included. If the Pro Override is disabled, the Pro Perk does not occur for the user except for /steal.
    • This is becuase when both Overrides are enabled, None-Pro Users can only steal up-to 50% of a User's Coin Balance. So when the Pro Override is disabled we allow Users to steal up-to 100% of the User's Coin Balance.

Topia Suspensions Override:

If the the Topia Suspensions Override is enabled (set to True), any User in the Suspended Users list will now no longer have Pro or be able to access Topia Commands.

Public Bot Override:

If the Public Bot Override is enabled (set to True) the Bot's Invite link will displayed in /help and in the main Links Button View, which is used across the bot, to allow users to invite the bot to their own server.

Production Mode Override:

If the Production Mode Override is disabled then the code will load Testing Token instead of Token.

Nuke Command Restrictions Override:

If the Nuke Command Restrictions Override is set to True (enabled), the No Nuke Command Servers list field must have at least one item inside.

Note

The items in the No Nuke Command Servers list field must be server/guild IDs.