galacticwarrior9 / IslamBot

A Discord bot that supports Qur'an, hadith, prayer times, tafsir and more.
GNU General Public License v3.0
88 stars 37 forks source link

Added all the rest of slash commands #35

Closed itzmk21 closed 2 years ago

itzmk21 commented 2 years ago

Summary of commits: -Fixed some grammar typos in messages -Changed the way typing is triggered -Fixed a lot of the old slash commands not working at all -Added the rest of the slash commands -Added a context menu #33 for hadith -Slight refactors to code -Rewrote set calc method to be representative of the slash equivalent -Added a methodlist command -Added relevant commands in help -In /dua removed the choices since not all are displayed -/(a)quran, /(a)tafsir and /mushaf now instead of referencing as 1:1 or 1:1-7 now is (#34): surah_num: 1 start_verse: 1 end_verse: optional: 7 (for tafsir and mushaf commands, start_verse is named verse_num with no end_verse since multiple ayahs with this command was never a feature) -Implemented the option to reference a surah by the revelation order (reveal_order opt in slash commands only) (#5) -Added a random mushaf command both text and slash

-Fixed #39

Massive PR, take your time checking it It's all been tested though.

Issues: -Errors are handled from cmds like -hadith with @hadith.error however, this cannot be implemented in the same manner with slash commands -/ireload raises an Exception saying something like "cannot await a NoneType" in reload_extension, however the actual reloading of the extension still works (-ireload works perfectly still) -We either have to migrate to something else that supports fluent error handling for slash commands or if there is a way with the current package, with that, else, manually have try, excepts in slash cmd funcs?