1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Twitch Viewer Bot - PhantomJS C#

Discussion in 'C, C++, C#' started by fluxo27, May 26, 2015.

  1. fluxo27

    fluxo27 Junior Member

    Joined:
    Apr 27, 2013
    Messages:
    183
    Likes Received:
    26
    Hello,

    I was thinking about making a twitch viewer bot with C# and PhantomJS.

    Can I have some imput whether you guys think that will work or not.
    (PhantomJS does not support flash)

    Thank you :)
     
  2. itz_styx

    itz_styx Jr. VIP Jr. VIP

    Joined:
    May 8, 2012
    Messages:
    366
    Likes Received:
    129
    Occupation:
    CEO / Admin / Developer
    Location:
    /dev/mem
    Home Page:
    need more details on what your bot should exactly do, maybe you dont even need phantomjs and is this still relevant as it was posted months ago?
     
  3. rootjazz

    rootjazz Jr. VIP Jr. VIP

    Joined:
    Dec 21, 2012
    Messages:
    684
    Likes Received:
    326
    Occupation:
    Developer
    Location:
    UK
    Home Page:
    Firstly figure out what is causing the view counter to increase. You might get lucky and just have to pull a single URL with some cookies set.

    If it is a mess of JS going on, you could try and work it all out or just use a browser such as phantomjs or any other selenium driven browser (doesn't have to be selenium but makes it easier if it is imo)

    If it is flash, then phantom will be no good and you will need to use ie / ff / chrome through selenium.
     
    • Thanks Thanks x 1
  4. ToxicBlack

    ToxicBlack Regular Member

    Joined:
    Mar 25, 2016
    Messages:
    223
    Likes Received:
    57
    Occupation:
    Programming custom bots and tools.
    Location:
    botland
    Yeah definitely, in this type of project go for a real browser with selenium. As of now it is very powerful and you can use Firefox or Chrome. Its the way to go.
     
    • Thanks Thanks x 1
  5. Dev Warrior

    Dev Warrior Jr. VIP Jr. VIP Premium Member

    Joined:
    Oct 13, 2015
    Messages:
    252
    Likes Received:
    30
    Home Page:
    I would suggest you to use PhantomJS; does twitch not support HTML5 video player? If not, of course you should use selenium with chrome or firefox drivers.
     
    • Thanks Thanks x 1
  6. REEND

    REEND Newbie

    Joined:
    May 31, 2015
    Messages:
    30
    Likes Received:
    1
    I also recommend Watij, easy to use and you can hide the web browser if you need it.