Discord.py Give users Roles based on Reaction in Python

แชร์
ฝัง
  • เผยแพร่เมื่อ 11 ธ.ค. 2024

ความคิดเห็น • 49

  • @-sheny215
    @-sheny215 ปีที่แล้ว

    good video, easy to follow, everything explained in detail so you can actually understand what u r doing - nice!

  • @crvasldaasd9850
    @crvasldaasd9850 3 ปีที่แล้ว +2

    Thank you! one normal youtuber who helped me figure out the reactions

    • @ExceedCodes
      @ExceedCodes  3 ปีที่แล้ว +1

      Thank you for watching!

  • @veerchauhan1616
    @veerchauhan1616 3 ปีที่แล้ว +2

    Thank you I was trying hard to do this for 3 days and after find your video

    • @ExceedCodes
      @ExceedCodes  3 ปีที่แล้ว +1

      Glad I could help, Hope you enjoy the series, Look forward to a new discord series coming soon with more advance stuff.

  • @mayankknirwan
    @mayankknirwan 3 ปีที่แล้ว +1

    Man im searching for this from like 2 days thanks a lot man 💯

  • @vineesh805
    @vineesh805 3 ปีที่แล้ว

    This Tutorial helped me a lot in coding my reaction role bot. Thank You So Much

  • @smeezy845
    @smeezy845 3 ปีที่แล้ว +1

    Very very well explanation and you earned a sub

    • @ExceedCodes
      @ExceedCodes  3 ปีที่แล้ว

      Thank you for watching!

  • @lucasgazzana8121
    @lucasgazzana8121 3 ปีที่แล้ว

    thank you dude, I was searching for this a long time

  • @maximus7184
    @maximus7184 3 ปีที่แล้ว +2

    What if I want the user to not be able to perform more than 3 roles?

  • @VOYD__
    @VOYD__ 3 ปีที่แล้ว +2

    Huge thanks to you my friend, u won a sub :)

    • @ExceedCodes
      @ExceedCodes  3 ปีที่แล้ว

      Thank you! Hope you enjoy the video :)

  • @incognitomodedev
    @incognitomodedev 3 ปีที่แล้ว

    Thanks man deserve a sub!

  • @mrigkrafts4859
    @mrigkrafts4859 3 ปีที่แล้ว +2

    can you tell me how to solve this error:
    Ignoring exception in on_raw_reaction_add
    discord.errors.Forbidden: 403 Forbidden (error code: 50013): Missing Permissions
    Ignoring exception in on_raw_reaction_remove

    • @mrigkrafts4859
      @mrigkrafts4859 3 ปีที่แล้ว +2

      it does mean that there is some permission the bot is missing, but when I checked I had given it the admin permission which includes every permission. So still what might be causing this and what must I do for solving it?

    • @ExceedCodes
      @ExceedCodes  3 ปีที่แล้ว +1

      I think that it has to do with the positioning of your bot's permission inside of discord itself. The error you are getting is due to your bot trying to assign a role to a user but its positioned lower than said role.
      I would go to the server the bot is in and got to the server setting, then I would go into Roles and I would move your bot's Role up to the top.

    • @mrigkrafts4859
      @mrigkrafts4859 3 ปีที่แล้ว +2

      @@ExceedCodes ok i shall try it and see if it works

    • @mrigkrafts4859
      @mrigkrafts4859 3 ปีที่แล้ว +2

      @@ExceedCodes yes now it works absolutely fine after shifting the places. Thanks for the help really!

  • @Fox28235
    @Fox28235 3 ปีที่แล้ว

    how to send a message when the roles are added? because ctx doesn't work

  • @sqaaq1
    @sqaaq1 3 ปีที่แล้ว +2

    Thank you very much man! Superb guide. And thx for timestamps! Make more vids :) Don't stop making new videos, I believe in u.
    And how we can do to have only 1 role from reaction? ex. I have 3 reactions, but I want to give someone only one role. Or I can't do this with bot, and supposed do it yourself w/ my own hands

    • @ExceedCodes
      @ExceedCodes  3 ปีที่แล้ว +2

      Mhm so if you want to restrict the user you would have to add an if statement above where you want to add your roles to check if they have any of the other roles

    • @sqaaq1
      @sqaaq1 3 ปีที่แล้ว +1

      @@ExceedCodes And if they already have a role, then not give them a new one?

    • @ExceedCodes
      @ExceedCodes  3 ปีที่แล้ว +2

      Yup! At least that’s what I assume you wanted to happen,

    • @sqaaq1
      @sqaaq1 3 ปีที่แล้ว +1

      @@ExceedCodes Ok, I should try this. Thank you! :)

  • @lolek4872
    @lolek4872 3 ปีที่แล้ว +2

    how to do it with nitro emoji? thank you

  • @novaop6267
    @novaop6267 3 ปีที่แล้ว +4

    bro can you pls upload you codes to github?
    and a suggestion: pls increase the font size :)
    btw great work

    • @ExceedCodes
      @ExceedCodes  3 ปีที่แล้ว +4

      Thank you! That means a lot to me. Later on in the series I increased the size of the code alongside a new style of presenting it. Check it out :)

    • @novaop6267
      @novaop6267 3 ปีที่แล้ว +2

      Yeah! Sure:)

  • @ExceedCodes
    @ExceedCodes  3 ปีที่แล้ว

    Hey guys! Join my Discord server to chat and hang or play with the bot we built
    discord.gg/QXWn8BZ8Sm

  • @0xk4b1r
    @0xk4b1r 2 ปีที่แล้ว

    amazing

  • @NINJAGAMING-vp4mh
    @NINJAGAMING-vp4mh 2 ปีที่แล้ว

    Hi bro, I am facing a error the error is "NameError: name 'ourMessageID' is not defined" do you have any idea on what to do?

    • @JustinS06
      @JustinS06 2 ปีที่แล้ว +1

      Yeah, your ourMessageID variable is not defined.... it literally says in the error.

  • @x_ragequit
    @x_ragequit 3 ปีที่แล้ว

    Hello! Everything I did worked, except the role wasn't added. Is there anything I did wrong?

  • @declankivlehan9821
    @declankivlehan9821 3 ปีที่แล้ว

    how did you get the bot to send the 'Welcome to Exceed' message? I don't see anything in your code.

    • @ExceedCodes
      @ExceedCodes  3 ปีที่แล้ว

      To get the bot to send something you would do await bot.send(embed=embed)

  • @matiasramirez7047
    @matiasramirez7047 3 ปีที่แล้ว +3

    Hello, I wanted to ask if the "on_raw_reaction_add" and "on_raw_reaction_remove" functions can be used again but with different variables or if they can only be used once.

    • @ExceedCodes
      @ExceedCodes  3 ปีที่แล้ว +2

      I would say that It could be used again but you might have to add a check that would look for the specific channel and then act upon the reactions in there which would allow you interact with the emojis else where

  • @alexandrumarinescu6991
    @alexandrumarinescu6991 3 ปีที่แล้ว

    Thank you for your video!
    Unfortunately, after following your example I have an error: "UnboundLocalError: local variable 'role' referenced before assignment" - it is related to the line: "await member.add_roles(role)". I found that it might be missing an "else". Have you met this error while building this specific bot function? Thank you.

  • @tigran7011
    @tigran7011 3 ปีที่แล้ว

    thank you bro so much!

  • @rezamando374
    @rezamando374 2 ปีที่แล้ว

    i need github

  • @Wiser51
    @Wiser51 3 ปีที่แล้ว

    got a thumbs up from me but i wouldve really appreciated it if you would’ve put the code in the description

  • @shineliao2399
    @shineliao2399 3 ปีที่แล้ว +1

    I search the API and didn’t find the guild in payload it just has guild_id
    Is that any difference or just the discord.py updates

    • @shineliao2399
      @shineliao2399 3 ปีที่แล้ว

      Oh sorry
      It just my fault

    • @ExceedCodes
      @ExceedCodes  3 ปีที่แล้ว

      Hey, Sorry for the late reply was on vacation, so the guild is an attribute of member which itself is apart of the payload.
      so shorten from what the video showed, it could be payload.member.guild