GithubHelp home page GithubHelp logo

Comments (7)

vogler avatar vogler commented on May 25, 2024

For now, you can increase the height here:

viewport: { width: 1280, height: 1280 },

You can only claim each game on one Twitch account and you usually select the same one?
What's the reason for having several linked?
Not sure if I have my Twitch still linked since they changed the client from Twitch to Amazon Gaming.
It's a bit hard to implement it remotely.
Maybe you can try the following:

  • run PWDEBUG=1 node epic-games
  • record the screen/windows with https://recordscreen.io/ (or similar, haven't tried it)
  • step through the debugger until the account selection
  • cmd + shift + C (ctrl on Win) to open DevTools and hover over thing to be clicked
  • in the Elements tab we now just need to find some way to identify it (text, CSS, other attributes)

from free-games-claimer.

vogler avatar vogler commented on May 25, 2024

@HandyHat01 I'll close this. Feel free to reopen with more details.

from free-games-claimer.

HandyHat01 avatar HandyHat01 commented on May 25, 2024

Hey @vogler, apologies for the delay in responding.

I ran npx cross-env PWDEBUG=1 node prime-gaming show and then recorded the window, stepping through the debugger until the account selection screen appeared. Changing the viewport size seemed to stop the code from working, so instead I zoomed out when the pop-up opened.

2022-07-15.21-09-46.mp4

What's the reason for having several linked?

I linked multiple back when the client was the Twitch client in order to allow family members to claim games I already owned.

from free-games-claimer.

vogler avatar vogler commented on May 25, 2024

Thanks for the video. In your normal browser the popup appears vertically centered? Strange that it shows up so low on the screen here.
It says "In order to claim content, please select a primary Twitch account.' and that it can be changed later.
Does this pop up for each game or does it remember your selection for some time?
Seems like it's not standard form elements and that the accounts are lazy-loaded since at 1:21 there's only Select an account.
You can try adding

await page.click('[data-a-target="select-twitch-account-modal__dropdown__header"]');
// TODO see what elements it loads and click one
await page.click('[data-a-target="select-twitch-account-modal__submit"]');

from free-games-claimer.

HandyHat01 avatar HandyHat01 commented on May 25, 2024

In your normal browser the popup appears vertically centered?

It does. The behaviour in the chromium window is odd.

Does this pop up for each game or does it remember your selection for some time?

Once selected, my selection is remembered in the browser until cookies are cleared/I'm logged out. The default Twitch account has to be selected again per browser though. I think this means once the user has selected once it can be ignored, just like logins.

I tried adding that code after

await (await card.$('button:has-text("Claim game")')).click();

but it fails because the popup isn't in view. Even though the code claims to be scrolling into view, it doesn't.

from free-games-claimer.

vogler avatar vogler commented on May 25, 2024

I'll add an option to change the used browser profile, then you can keep a profile for each Twitch account (still have to select it initially though).

from free-games-claimer.

vogler avatar vogler commented on May 25, 2024

You can now use BROWSER_DIR=data/browser2 node prime-gaming.js to claim for several accounts.

from free-games-claimer.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.