-
Notifications
You must be signed in to change notification settings - Fork 706
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
Drop collection #21
Comments
In Italy the use of all Twitch functionality is not diffused, and also I am not an expert. Can you provide also a screenshot for this drop reward/button etc? Maybe this can help me understand ... Anyway, I want to reduce the usage of Selenium, currently is required only for the Bet, and I've also written a POC for do only with API. We should implement also this 'Drop collection function' with API if It's possible |
Inventory During: https://prnt.sc/xq5n15 |
Sorry bro but I don't know what are you talking about 😂 Any steps to reproduce so I can try by myself? Maybe it's related to the watch increasing-time in based on chat, like the issue at this link |
Also I don't know If we have a different endpoints or xpath buttons for each games. I think the drops are game related, right? |
To me it looks similar to https://www.twitch.tv/drops/campaigns |
Yes this is partially the same issue.
The screenshots I posted as from "https://www.twitch.tv/drops/inventory" showing one from a collection of drops partially rewarded and then the second image shows it finished where the claim button appears. This needs clicking for the next drop to start unlocking, its not automatic. |
OK, so for testing I should link my Twitch account on one of games with drops enable.
|
https://www.protondb.com/app/1049590 But happy to test :) |
Do you think It's possible to register and account on this game, linked on Twitch and claim the bonus without install or play the game? 😆 Really, I've too much problem with my PC. First I've not enough space, I should format everything and change SSD, but I want to complete my University thesis first. |
For increase the watching-time we could integrate one of the following projects:
If someone wants to try. |
I tried using Chatterino today to see if joining chat increased watch time reward status but it didn't. |
Guys the view-count for drops It's not chat-related. This is a proof, every minute the value on The only update we should to do Is to add the game name in the requested with event:
Twitch-Channel-Points-Miner-v2/TwitchChannelPointsMiner/classes/Twitch.py Lines 250 to 254 in 6e1f74c
event_properties = {
"channel_id": 123456,
"broadcast_id": 123456,
"player": "site",
"user_id": 123456,
"game": "Eternal Return: Black Survival",
}
minute_watched = [{"event": "minute-watched", "properties": event_properties}]
json_event = json.dumps(minute_watched, separators=(",", ":"))
payload = {"data": (b64encode(json_event.encode("utf-8"))).decode("utf-8")}
response = requests.post('https://spade-url', headers=headers, data=payload) This is the CURL request for check if the counter is increased:
Anyway, I think I'll do initially a new branch just for test the increase time. |
Wow, that's fantastic work. |
…drops. Insert the game name (if drops are enabled) in minute_watched request. Ref #21
Guys, I need some testers please! Someone can try this branch on latest commit? 🙏 @SiIason ? I need also If it's possible a collection of all message starting with: Drop update
|
Working great... Checked with Twitch and the reward counter is increasing.
|
Thanks for your time. And I would other type for continue the implementation of this. For example I could check every update if |
Seems like it works for some drops but not all? Like for now on Rainbow Six streams, drops are activated (eg: https://www.twitch.tv/kinggeorge). This line is fireing well and I see the game in the logs Though the drops are not detected as this line doesn't fire Now maybe a difference is that these drops doesn't appear in the page https://www.twitch.tv/drops/campaigns . |
For the moment I've enabled the increase counters only for the streams with "Drop enable" tag. Missing here. I seen that the drops are enabled only in the title and in the chat, with stream elements and command I don't know if this drops type are developed by third part, and not directly form Twitch 🤔 This is only an Idea but It's possibile that If this drop are developed not from Twitch the counter Is chat based, test with chatterino if the counter increase. About the counter I'm not sure that you have a counter, because the drops event Is not in Inventory page. I want to repeat again, maybe It's something developed by Ubisoft in this case. Test chatterino, If you notice some differences report here and we can try to find a solution. For sure we can't claim the drop for you. |
Oh! wait 😢 @RakSrinaNa You can try also to edit the following line and remove the If that search for id:
if 1==1 or "c2542d6d-cd10-4532-919b-3d19f30a768b" in [tag['id'] for tag in streamer_info['stream']['tags']]: |
For understand as well who is chat-related and not you can try the pop up mode for player and for chat. |
For now I'm running this script while sending the game everytime (with 1==1) to see if it does anything. But this will be quite hard to tell as there's no "progress bar" or anything. You only know when you get the drop itself. Probably that Ubisoft gets a list of watched time or something and decides by themselves when giving the drop? I'll let it on through the day and try not to add too much time to it through Twitch. Though looking a bit through Twitch's requests, I can see this response passing by: {
"data": {
"user": {
"id": "194258396",
"login": "fastanne",
"displayName": "FastAnne",
"lastBroadcast": {
"id": "40909281340",
"game": {
"id": "460630",
"self": {
"isDropsLinked": true,
"__typename": "GameSelfConnection"
},
"activeDropCampaigns": [
{
"id": "fff3dad0-0efe-4048-ae4e-02ae33e79678",
"connectionURL": "https://drops-register.ubi.com/",
"applicableChannels": [],
"isAvailableToAllChannels": true,
"__typename": "DropCampaign"
}
],
"__typename": "Game"
},
"__typename": "Broadcast"
},
"stream": {
"id": "40909281340",
"isStreamDropsEnabled": true,
"type": "live",
"__typename": "Stream"
},
"__typename": "User"
}
},
"extensions": {
"durationMilliseconds": 59,
"operationName": "Drops_ChannelDrops_User",
"requestID": "01EX6VGJ6R9R87M1TDS2QJPENC"
}
}
Request: {
"operationName": "Drops_ChannelDrops_User",
"variables": {
"login": "fastanne",
"isLoggedIn": true
},
"extensions": {
"persistedQuery": {
"version": 1,
"sha256Hash": "f309b1d517d288074d50d96512059857cc67d8905d1379e414d70f7b981f2618"
}
}
} |
Or just check who are online in chat and share randomly the drop 🤔 |
About sending the game info we can do it every time, It's not a problem. The strangest thing here If you use the same request {
"data": {
"user": {
"id": "00000",
"login": "streamer",
"displayName": "streamer",
"lastBroadcast": {
"id": "00000",
"game": {
"id": "00000",
"self": {
"isDropsLinked": false,
"__typename": "GameSelfConnection"
},
"activeDropCampaigns": [],
"__typename": "Game"
},
"__typename": "Broadcast"
},
"stream": {
"id": "00000",
"isStreamDropsEnabled": false,
"type": "live",
"__typename": "Stream"
},
"__typename": "User"
}
},
"extensions": {
"durationMilliseconds": 58,
"operationName": "Drops_ChannelDrops_User",
"requestID": "01EX6ZWKPAGB5C6P11NPCTN3R3"
}
} |
On R6 you doesn't needed to claim reward, it claims automatically |
Excuse my ignorance, R6 stand for Rainbow Six? |
It's possible that Sector's Edge It's different from Eternal Return? I think we can claim at least 3 of this +50% Proton Boost
About this I don't understand. Sorry |
It looks stuck now. Looks like this https://prnt.sc/xtkknh
|
I only get "Drop update" messages from the second campaign/game when then first campaign doesn't check for drops |
Checking again Twitch now says I've clamed two rewards (at the bottom of the page) even though the second looks unclaimed as you can see from previous screenshot and the "Drop update" log message is still stuck reporting 15/15 |
If you can please do a |
New pull Initial Observations: |
Yes It's correct. Also, if you use Twitch you will see the same reward multiple times. |
Your right but that's not what I was referring to. |
OK, you are right. There is something wrong here 🤣 |
Stuck again now : https://prnt.sc/xtmwf6 Will wait for you to update before continuing. |
…uired check the drop in inventory and get the dropInstanceID for auto-claim #21 Signed-off-by: Alessandro Maggio <[email protected]>
@SiIason . New commit ready for test 🔥 |
Ermmm: https://prnt.sc/xtqci5 Had to manually collect the two outstanding drops before anything happened. |
I'm going to watch normally to see if I can get them back to normal. |
Weird they aren't queued up on each other though, its like double/triple rewards for time watched. Down to 1 timer on the 200% reward. Maybe it was all as planned? Maybe the initial script set something wonky? |
Are you able to check if any items are ready to claim before 'watching' for new items. (at script startup) |
LOL. I think It's only a different claim system for this game. Nothing else.
Do you mean to claim all pending reward on startup? |
Yes |
Assuming we're all good here :) a few quality of life ideas. Would you like me to submit these as improvments?
|
This is OK for me. I'll do as usually as argument, so a user can choose to claim all drops on startup or not.
I know which streamer s gaining rewards because I have the channel_id for each 'drop-progress' type. So I don't understand why and what I should restrict. I mean, I don't check anything 🤣 I've only the periodic update from WebSocket. Or you would suggest sending game name in request only for one streamer at once? It's possible that I have not understood you. My English It's not the best
If I understand correctly this is related to the 2. ? Assume my script stop sending the WatchMinuteEvent but we are listening for drop-progress topics (via WebSocket). In this case If you watch manually a stream we will receive the event and when current time is equal to required time we will go claim the drop. |
This. Yet to see multiple games be rewarded at the same time. |
yes, leave as it for the moment |
Current repo implementation does not count viewing time towards timed Drop rewards.
The example I looked at needs to be claimed (button clicked) every hour to continue earning towards watched time. So simply going afk only ever builds up time for 1 drop. You can Claim via a popup message box in chat (same as channel points) or via the inventory page, you could have multiple claim buttons here. I've included code for both buttons should they require css descriptors.
twitchchatclaimbutton.txt
twitchinventoryclaimbutton.txt
I assume this also means other types of Drop reward are not able to be collected?
Solution could be to keep the channel stream open, which I don't believe currently happens, clicking the claim button when it appears. Most pages have the "drops enabled" tag so wouldn't need to happen if no drops enabled. Or a periodic check of your inventory for available items to be claimed could be a simpler catch-all (assuming watch progress starts to be recorded).
The text was updated successfully, but these errors were encountered: