Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simple kakera implementation is not working #246

Open
xd-mau5 opened this issue Jul 11, 2023 · 13 comments
Open

Simple kakera implementation is not working #246

xd-mau5 opened this issue Jul 11, 2023 · 13 comments

Comments

@xd-mau5
Copy link

xd-mau5 commented Jul 11, 2023

Since i saw the commit of the kakera implementation i tried, but for me it doesn't work at all as you can see in the logs and the image
image
(I clicked the kakera button)

Jul 11 13:44:55 mau5-v2 bash[184330]: True: Waifu rolling : 1050623065127657482
Jul 11 13:45:52 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:45:53 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:45:54 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:45:57 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:45:59 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:02 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:04 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:07 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:09 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:12 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:14 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:17 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:19 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:22 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:24 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:27 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:29 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:32 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:34 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:38 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482
Jul 11 13:46:48 mau5-v2 bash[184330]: Our user rolled in 1050623065127657482

Looks like it depends on the guildID

@vivinano
Copy link
Owner

It looks like it clicked the kakera ?

@vivinano
Copy link
Owner

I changed the guild id call to using a get method like the character sniping uses we will see if it works now.

@xd-mau5
Copy link
Author

xd-mau5 commented Jul 11, 2023

I changed the guild id call to using a get method like the character sniping uses we will see if it works now.

Tried and still doesn't do anything
image

Jul 11 14:56:10 mau5-v2 bash[207375]: 7200 : pokerolling : 1050623065127657482
Jul 11 14:56:13 mau5-v2 bash[207375]: 72000 : daily_rolling : 1050623065127657482
Jul 11 14:56:31 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:56:32 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:56:33 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:56:34 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:56:40 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:56:47 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:56:48 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:56:49 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:56:50 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:56:50 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:56:51 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:56:52 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:56:58 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:56:59 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:57:01 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:57:02 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:57:03 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:57:04 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:57:05 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:57:06 mau5-v2 bash[207375]: Our user rolled in 1050623065127657482
Jul 11 14:57:06 mau5-v2 bash[207375]: True: Waifu rolling : 1050623065127657482

@vivinano
Copy link
Owner

is it in your kakera vari list

@xd-mau5
Copy link
Author

xd-mau5 commented Jul 11, 2023

is it in your kakera vari list

This is my current config for the kakera, is the same as the repo

"emoji_list":[
	  "kakera",	
      "kakeraT",
      "kakeraG",
      "kakeraY",
      "kakeraO",
      "kakeraR",
      "kakeraW",
      "kakeraL"
   ],
   "soulemoji_list":[
      "kakeraO",
      "kakeraR",
      "KakeraW",
      "KakeraL"
   ],

@vivinano
Copy link
Owner

unsure what is going on there try to lower the kakeravari also maybe its a caps issue

@xd-mau5
Copy link
Author

xd-mau5 commented Jul 11, 2023

This is my full settings without token

{
   "token":"token",
   "channel_ids":[
	  1050623065127657482
   ],
   "slash_ids":[
	  1050611814536331334
   ],
   "slash_guild_ids":[
      1050611814536331334
   ],
   "claim_delay":0,
   "kak_delay":0,
   "use_emoji":"<:keqing_love:795077041761288214>",
   "roll_this":"ma",
   "rolling":"True",
   "slash_rolling":"True",
   "pkmrolling":"True",
   "series_list":[
   ],
   "namelist":[
   ],
   "emoji_list":[
	  "kakera",	
      "kakeraT",
      "kakeraG",
      "kakeraY",
      "kakeraO",
      "kakeraR",
      "kakeraW",
      "kakeraL"
   ],
   "soulemoji_list":[
      "kakeraO",
      "kakeraR",
      "KakeraW",
      "KakeraL"
   ],
   "min_kak":150,
   "Last_True":"False",
   "last_claim_min": 61,
   "min_kak_last_min": 10
}

I don't see anything wrong

@JuliaYuki
Copy link

"emoji_list": [ "Kakera", "KakeraG", "KakeraT", "KakeraY", "KakeraO", "KakeraR", "KakeraW", "KakeraL" ], "soulemoji_list": [ "KakeraP", "KakeraY", "KakeraO", "KakeraR", "KakeraW", "KakeraL" ],

I saw that some words had the letter "k" in lowercase and others in uppercase. I tried uppercase and then lowercase. None of the ways worked to react to kakera.

@Nicksw21
Copy link

Did you guys manage to fix the kakera react issue?

@Nixeld
Copy link

Nixeld commented Nov 5, 2023

image
Quick fix. Add the following code there.

        snipe_delay = channel_settings[int(channelid)]['kak_snipe'][1]

        if butts.components != [] :
            buttMoji = butts.components[0]["components"][0]["emoji"]["name"]
            if buttMoji.lower() in KakeraVari:
                time.sleep(snipe_delay+1)
                bot.click(
                aId,
                channelID=m["channel_id"],
                guildID=m.get("guild_id"),
                messageID=m["id"],
                messageFlags=m["flags"],
                data=butts.getButton(emojiName=buttMoji),
                )

Basically just moved the code for clicking on the button to the top because it wasn't reaching the bottom when a button is on the message for some reason.

@VineST
Copy link

VineST commented Nov 9, 2023

Nixeld, thank you! I missed the .lower() at first and was confused at it still failing to match the kakeras to my list of desired reacts. It being case sensitive explains that. Working great now!

@VineST
Copy link

VineST commented Nov 10, 2023

image
The kakera code still works almost always, but occasionally it randomly fails to click a button. I added two debug lines to try identifying the issue, but all looks good on the code end. Later in that rolling session, 2 yellow and 1 purple appeared and were properly interacted with. (Not relevant to this issue, but purple isn't in the config by default—I decided to add that one, because it's literally free, and removed blue/teal/green).

@vivinano
Copy link
Owner

it just makes it a little harder due to buttons not having their own gateway as of yet. when i have more time ill look into more ways to solve the issues but currently i havent had the downtime in my personal life

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants